C# client for the ComboCurve REST API
View the Project on GitHub insidepetroleum/combocurve-client-csharp
All URIs are relative to https://api.combocurve.com
Method | HTTP request | Description |
---|---|---|
DeleteScenarioWellsDelete | DELETE /v1/projects/{projectId}/scenarios/{scenarioId}/well-assignments | |
GetScenarioWellsRead | GET /v1/projects/{projectId}/scenarios/{scenarioId}/well-assignments | |
PostScenarioWellsUpsert | POST /v1/projects/{projectId}/scenarios/{scenarioId}/well-assignments | |
PutScenarioWellsUpsert | PUT /v1/projects/{projectId}/scenarios/{scenarioId}/well-assignments |
void DeleteScenarioWellsDelete (string scenarioId, string projectId, string wells)
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 DeleteScenarioWellsDeleteExample
{
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 ScenarioWellAssignmentsApi(serviceAccount, apiKey);
var scenarioId = "scenarioId_example"; // string |
var projectId = "projectId_example"; // string |
var wells = new string[] { "wells_example" }; // IEnumerable<string> |
try
{
apiInstance.DeleteScenarioWellsDelete(scenarioId, projectId, wells);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ScenarioWellAssignmentsApi.DeleteScenarioWellsDelete: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
scenarioId | string | ||
projectId | string | ||
wells | string |
void (empty response body)
API Key, Service Account
| Status code | Description | Response headers | |————-|————-|——————| | 204 | NoContent Response | * x-delete-count - | | 404 | NotFound Response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ScenarioWellsReadOKResponse GetScenarioWellsRead (string scenarioId, string projectId)
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 GetScenarioWellsReadExample
{
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 ScenarioWellAssignmentsApi(serviceAccount, apiKey);
var scenarioId = "scenarioId_example"; // string |
var projectId = "projectId_example"; // string |
try
{
ScenarioWellsReadOKResponse result = apiInstance.GetScenarioWellsRead(scenarioId, projectId);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ScenarioWellAssignmentsApi.GetScenarioWellsRead: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
scenarioId | string | ||
projectId | string |
API Key, Service Account
| 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]
ScenarioWellsUpsertMultiStatusResponse PostScenarioWellsUpsert (string scenarioId, string projectId, List
wells)
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 PostScenarioWellsUpsertExample
{
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 ScenarioWellAssignmentsApi(serviceAccount, apiKey);
var scenarioId = "scenarioId_example"; // string |
var projectId = "projectId_example"; // string |
var wells = new List<string>(); // List<string> |
try
{
ScenarioWellsUpsertMultiStatusResponse result = apiInstance.PostScenarioWellsUpsert(scenarioId, projectId, wells);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ScenarioWellAssignmentsApi.PostScenarioWellsUpsert: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
scenarioId | string | ||
projectId | string | ||
wells | List<string> |
ScenarioWellsUpsertMultiStatusResponse
API Key, Service Account
| Status code | Description | Response headers | |————-|————-|——————| | 207 | MultiStatus Response | - | | 400 | BadRequest Response | - | | 404 | NotFound Response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ScenarioWellsUpsertMultiStatusResponse PutScenarioWellsUpsert (string scenarioId, string projectId, List
wells)
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 PutScenarioWellsUpsertExample
{
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 ScenarioWellAssignmentsApi(serviceAccount, apiKey);
var scenarioId = "scenarioId_example"; // string |
var projectId = "projectId_example"; // string |
var wells = new List<string>(); // List<string> |
try
{
ScenarioWellsUpsertMultiStatusResponse result = apiInstance.PutScenarioWellsUpsert(scenarioId, projectId, wells);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ScenarioWellAssignmentsApi.PutScenarioWellsUpsert: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
scenarioId | string | ||
projectId | string | ||
wells | List<string> |
ScenarioWellsUpsertMultiStatusResponse
API Key, Service Account
| Status code | Description | Response headers | |————-|————-|——————| | 207 | MultiStatus Response | - | | 400 | BadRequest Response | - | | 404 | NotFound Response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]