All URIs are relative to https://api.egoiapp.com
| Method | HTTP request | Description |
|---|---|---|
| createCName | POST /cnames | Create cname |
| getAllCNames | GET /cnames | Get All CNames |
CName createCName(cnamePost)
Create cname
Creates a cnames
// Import classes:
import org.egoi.client.ApiClient;
import org.egoi.client.ApiException;
import org.egoi.client.Configuration;
import org.egoi.client.auth.*;
import org.egoi.client.models.*;
import org.egoi.client.api.CNamesApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.egoiapp.com");
// Configure API key authorization: Apikey
ApiKeyAuth Apikey = (ApiKeyAuth) defaultClient.getAuthentication("Apikey");
Apikey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Apikey.setApiKeyPrefix("Token");
CNamesApi apiInstance = new CNamesApi(defaultClient);
CNamePost cnamePost = new CNamePost(); // CNamePost | Parameters for the cname
try {
CName result = apiInstance.createCName(cnamePost);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling CNamesApi#createCName");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| cnamePost | CNamePost | Parameters for the cname |
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 201 | Created | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 408 | Request Timeout | - |
| 409 | Conflict | - |
| 422 | Unprocessable Entity | - |
| 429 | Too Many Requests | - |
| 500 | Internal Server Error | - |
| 503 | Service Unavailable | - |
CNamesCollection getAllCNames()
Get All CNames
Returns all cnames
// Import classes:
import org.egoi.client.ApiClient;
import org.egoi.client.ApiException;
import org.egoi.client.Configuration;
import org.egoi.client.auth.*;
import org.egoi.client.models.*;
import org.egoi.client.api.CNamesApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.egoiapp.com");
// Configure API key authorization: Apikey
ApiKeyAuth Apikey = (ApiKeyAuth) defaultClient.getAuthentication("Apikey");
Apikey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Apikey.setApiKeyPrefix("Token");
CNamesApi apiInstance = new CNamesApi(defaultClient);
try {
CNamesCollection result = apiInstance.getAllCNames();
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling CNamesApi#getAllCNames");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 401 | Unauthorized | - |
| 403 | Forbidden | - |
| 408 | Request Timeout | - |
| 422 | Unprocessable Entity | - |
| 429 | Too Many Requests | - |
| 500 | Internal Server Error | - |
| 503 | Service Unavailable | - |