Skip to content

Latest commit

 

History

History
157 lines (100 loc) · 4.87 KB

File metadata and controls

157 lines (100 loc) · 4.87 KB

HyperstackApi.OrganizationApi

All URIs are relative to https://infrahub-api.nexgencloud.com/v1

Method HTTP request Description
removeOrganizationMember POST /auth/organizations/remove-member Remove Organization Member
retrieveOrganizationInformation GET /auth/organizations Retrieve Organization Information
updateOrganizationInformation PUT /auth/organizations/update Update Organization Information

removeOrganizationMember

RemoveMemberFromOrganizationResponseModel removeOrganizationMember(payload)

Remove Organization Member

Removes a member from your organization. For additional information, click here.

Example

import HyperstackApi from '@nexgencloud/hyperstack-sdk-javascript';
let defaultClient = HyperstackApi.ApiClient.instance;
// Configure API key authorization: apiKey
let apiKey = defaultClient.authentications['apiKey'];
apiKey.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.apiKeyPrefix = 'Token';

let apiInstance = new HyperstackApi.OrganizationApi();
let payload = new HyperstackApi.RemoveMemberPayload(); // RemoveMemberPayload | 
apiInstance.removeOrganizationMember(payload).then((data) => {
  console.log('API called successfully. Returned data: ' + data);
}, (error) => {
  console.error(error);
});

Parameters

Name Type Description Notes
payload RemoveMemberPayload

Return type

RemoveMemberFromOrganizationResponseModel

Authorization

apiKey

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

retrieveOrganizationInformation

GetOrganizationResponseModel retrieveOrganizationInformation()

Retrieve Organization Information

Retrieves detailed information about your organization, including current credit, threshold, number of instances, and number of volumes. For additional information on organizations, click here.

Example

import HyperstackApi from '@nexgencloud/hyperstack-sdk-javascript';
let defaultClient = HyperstackApi.ApiClient.instance;
// Configure API key authorization: apiKey
let apiKey = defaultClient.authentications['apiKey'];
apiKey.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.apiKeyPrefix = 'Token';

let apiInstance = new HyperstackApi.OrganizationApi();
apiInstance.retrieveOrganizationInformation().then((data) => {
  console.log('API called successfully. Returned data: ' + data);
}, (error) => {
  console.error(error);
});

Parameters

This endpoint does not need any parameter.

Return type

GetOrganizationResponseModel

Authorization

apiKey

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

updateOrganizationInformation

UpdateOrganizationResponseModel updateOrganizationInformation(payload)

Update Organization Information

Updates the name of the organization. For additional information, click here.

Example

import HyperstackApi from '@nexgencloud/hyperstack-sdk-javascript';
let defaultClient = HyperstackApi.ApiClient.instance;
// Configure API key authorization: apiKey
let apiKey = defaultClient.authentications['apiKey'];
apiKey.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.apiKeyPrefix = 'Token';

let apiInstance = new HyperstackApi.OrganizationApi();
let payload = new HyperstackApi.UpdateOrganizationPayload(); // UpdateOrganizationPayload | 
apiInstance.updateOrganizationInformation(payload).then((data) => {
  console.log('API called successfully. Returned data: ' + data);
}, (error) => {
  console.error(error);
});

Parameters

Name Type Description Notes
payload UpdateOrganizationPayload

Return type

UpdateOrganizationResponseModel

Authorization

apiKey

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json