combocurve-client-csharp

Logo

C# client for the ComboCurve REST API

View the Project on GitHub insidepetroleum/combocurve-client-csharp

ComboCurve.Api.Api.InventoryScenarioQualifiersApi

All URIs are relative to https://api.combocurve.com

Method HTTP request Description
DeleteInventoryScenarioQualifiers DELETE /v1/projects/{projectId}/inventory/scenarios/{scenarioId}/qualifiers Deletes qualifiers of an inventory scenario. A regular scenario is not found.
GetInventoryScenarioQualifiers GET /v1/projects/{projectId}/inventory/scenarios/{scenarioId}/qualifiers Returns the qualifiers of an inventory scenario, grouped by econ model. A regular scenario is not found.
PostInventoryScenarioQualifiers POST /v1/projects/{projectId}/inventory/scenarios/{scenarioId}/qualifiers Adds qualifiers to an inventory scenario. A regular scenario is not found.
PutInventoryScenarioQualifiers PUT /v1/projects/{projectId}/inventory/scenarios/{scenarioId}/qualifiers Renames qualifiers of an inventory scenario. A regular scenario is not found.

DeleteInventoryScenarioQualifiers

void DeleteInventoryScenarioQualifiers (string scenarioId, string projectId, string econNames, string qualifierNames)

Deletes qualifiers of an inventory scenario. A regular scenario is not found.

Example

using System;
using System.Collections.Generic;
using System.Diagnostics;
using ComboCurve.Api.Api;
using ComboCurve.Api.Auth;
using ComboCurve.Api.Client;
using ComboCurve.Api.Model;

namespace Example
{
    public class DeleteInventoryScenarioQualifiersExample
    {
        public static void Main()
        {
            // Use this to create your service account manually
            var serviceAccount = new ServiceAccount
            {
                ClientEmail = "YOUR_CLIENT_EMAIL",
                ClientId = "YOUR_CLIENT_ID",
                PrivateKey = "YOUR_PRIVATE_KEY"
            };

            // Or use this to load it from a JSON file
            // var serviceAccount = ServiceAccount.FromFile("PATH_TO_JSON_FILE");

            // Set your API key
            var apiKey = "YOUR_API_KEY";

            var apiInstance = new ComboCurveV1Api(serviceAccount, apiKey);

			// Or use the specific API class (Recommended)
			// var apiInstance = new InventoryScenarioQualifiersApi(serviceAccount, apiKey);

            var scenarioId = "scenarioId_example";  // string | 
            var projectId = "projectId_example";  // string | 
            var econNames = new string[] { "econNames_example" };  // IEnumerable<string> | 
            var qualifierNames = new string[] { "qualifierNames_example" };  // IEnumerable<string> | 

            try
            {
                // Deletes qualifiers of an inventory scenario. A regular scenario is not found.
                apiInstance.DeleteInventoryScenarioQualifiers(scenarioId, projectId, econNames, qualifierNames);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling InventoryScenarioQualifiersApi.DeleteInventoryScenarioQualifiers: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
scenarioId string    
projectId string    
econNames string    
qualifierNames string    

Return type

void (empty response body)

Authorization

API Key, Service Account

HTTP request headers

HTTP response details

| Status code | Description | Response headers | |————-|————-|——————| | 204 | NoContent Response | * x-delete-count - | | 400 | BadRequest Response | - | | 404 | NotFound Response | - | | 409 | Conflict Response. The scenario changed while the request was processed. Retry the request. | - |

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetInventoryScenarioQualifiers

InventoryScenarioQualifiersReadOKResponse GetInventoryScenarioQualifiers (string scenarioId, string projectId, string econName = null)

Returns the qualifiers of an inventory scenario, grouped by econ model. A regular scenario is not found.

Example

using System;
using System.Collections.Generic;
using System.Diagnostics;
using ComboCurve.Api.Api;
using ComboCurve.Api.Auth;
using ComboCurve.Api.Client;
using ComboCurve.Api.Model;

namespace Example
{
    public class GetInventoryScenarioQualifiersExample
    {
        public static void Main()
        {
            // Use this to create your service account manually
            var serviceAccount = new ServiceAccount
            {
                ClientEmail = "YOUR_CLIENT_EMAIL",
                ClientId = "YOUR_CLIENT_ID",
                PrivateKey = "YOUR_PRIVATE_KEY"
            };

            // Or use this to load it from a JSON file
            // var serviceAccount = ServiceAccount.FromFile("PATH_TO_JSON_FILE");

            // Set your API key
            var apiKey = "YOUR_API_KEY";

            var apiInstance = new ComboCurveV1Api(serviceAccount, apiKey);

			// Or use the specific API class (Recommended)
			// var apiInstance = new InventoryScenarioQualifiersApi(serviceAccount, apiKey);

            var scenarioId = "scenarioId_example";  // string | 
            var projectId = "projectId_example";  // string | 
            var econName = new string[] { "econName_example" };  // IEnumerable<string> |  (optional)

            try
            {
                // Returns the qualifiers of an inventory scenario, grouped by econ model. A regular scenario is not found.
                InventoryScenarioQualifiersReadOKResponse result = apiInstance.GetInventoryScenarioQualifiers(scenarioId, projectId, econName);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling InventoryScenarioQualifiersApi.GetInventoryScenarioQualifiers: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
scenarioId string    
projectId string    
econName string   [optional]

Return type

InventoryScenarioQualifiersReadOKResponse

Authorization

API Key, Service Account

HTTP request headers

HTTP response details

| Status code | Description | Response headers | |————-|————-|——————| | 200 | OK Response | - | | 404 | NotFound Response | - |

[Back to top] [Back to API list] [Back to Model list] [Back to README]

PostInventoryScenarioQualifiers

InventoryScenarioQualifiersUpsertMultiStatusResponse PostInventoryScenarioQualifiers (string scenarioId, string projectId, List payload)

Adds qualifiers to an inventory scenario. A regular scenario is not found.

Example

using System;
using System.Collections.Generic;
using System.Diagnostics;
using ComboCurve.Api.Api;
using ComboCurve.Api.Auth;
using ComboCurve.Api.Client;
using ComboCurve.Api.Model;

namespace Example
{
    public class PostInventoryScenarioQualifiersExample
    {
        public static void Main()
        {
            // Use this to create your service account manually
            var serviceAccount = new ServiceAccount
            {
                ClientEmail = "YOUR_CLIENT_EMAIL",
                ClientId = "YOUR_CLIENT_ID",
                PrivateKey = "YOUR_PRIVATE_KEY"
            };

            // Or use this to load it from a JSON file
            // var serviceAccount = ServiceAccount.FromFile("PATH_TO_JSON_FILE");

            // Set your API key
            var apiKey = "YOUR_API_KEY";

            var apiInstance = new ComboCurveV1Api(serviceAccount, apiKey);

			// Or use the specific API class (Recommended)
			// var apiInstance = new InventoryScenarioQualifiersApi(serviceAccount, apiKey);

            var scenarioId = "scenarioId_example";  // string | 
            var projectId = "projectId_example";  // string | 
            var payload = new List<InventoryScenarioQualifierUpsertPayload>(); // List<InventoryScenarioQualifierUpsertPayload> | 

            try
            {
                // Adds qualifiers to an inventory scenario. A regular scenario is not found.
                InventoryScenarioQualifiersUpsertMultiStatusResponse result = apiInstance.PostInventoryScenarioQualifiers(scenarioId, projectId, payload);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling InventoryScenarioQualifiersApi.PostInventoryScenarioQualifiers: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
scenarioId string    
projectId string    
payload List<InventoryScenarioQualifierUpsertPayload>    

Return type

InventoryScenarioQualifiersUpsertMultiStatusResponse

Authorization

API Key, Service Account

HTTP request headers

HTTP response details

| Status code | Description | Response headers | |————-|————-|——————| | 207 | MultiStatus Response | - | | 404 | NotFound Response | - |

[Back to top] [Back to API list] [Back to Model list] [Back to README]

PutInventoryScenarioQualifiers

InventoryScenarioQualifiersUpsertMultiStatusResponse PutInventoryScenarioQualifiers (string scenarioId, string projectId, List payload)

Renames qualifiers of an inventory scenario. A regular scenario is not found.

Example

using System;
using System.Collections.Generic;
using System.Diagnostics;
using ComboCurve.Api.Api;
using ComboCurve.Api.Auth;
using ComboCurve.Api.Client;
using ComboCurve.Api.Model;

namespace Example
{
    public class PutInventoryScenarioQualifiersExample
    {
        public static void Main()
        {
            // Use this to create your service account manually
            var serviceAccount = new ServiceAccount
            {
                ClientEmail = "YOUR_CLIENT_EMAIL",
                ClientId = "YOUR_CLIENT_ID",
                PrivateKey = "YOUR_PRIVATE_KEY"
            };

            // Or use this to load it from a JSON file
            // var serviceAccount = ServiceAccount.FromFile("PATH_TO_JSON_FILE");

            // Set your API key
            var apiKey = "YOUR_API_KEY";

            var apiInstance = new ComboCurveV1Api(serviceAccount, apiKey);

			// Or use the specific API class (Recommended)
			// var apiInstance = new InventoryScenarioQualifiersApi(serviceAccount, apiKey);

            var scenarioId = "scenarioId_example";  // string | 
            var projectId = "projectId_example";  // string | 
            var payload = new List<InventoryScenarioQualifierUpsertPayload>(); // List<InventoryScenarioQualifierUpsertPayload> | 

            try
            {
                // Renames qualifiers of an inventory scenario. A regular scenario is not found.
                InventoryScenarioQualifiersUpsertMultiStatusResponse result = apiInstance.PutInventoryScenarioQualifiers(scenarioId, projectId, payload);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling InventoryScenarioQualifiersApi.PutInventoryScenarioQualifiers: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
scenarioId string    
projectId string    
payload List<InventoryScenarioQualifierUpsertPayload>    

Return type

InventoryScenarioQualifiersUpsertMultiStatusResponse

Authorization

API Key, Service Account

HTTP request headers

HTTP response details

| Status code | Description | Response headers | |————-|————-|——————| | 207 | MultiStatus Response | - | | 404 | NotFound Response | - |

[Back to top] [Back to API list] [Back to Model list] [Back to README]