NAV Navigation
OSC CLI Shell Python

3DS OUTSCALE API v1.16

Welcome to the OUTSCALE API documentation.

The OUTSCALE API enables you to manage your resources in the OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the OUTSCALE API. You can find a list of the differences here.

You can also manage your resources using the Cockpit web interface.

Base URLs:

Terms of service Email: Support License: BSD 3 Clause

Authentication

AccessKey

CreateAccessKey

POST /CreateAccessKey

Creates a new secret access key and the corresponding access key ID for a specified user. The created key is automatically set to ACTIVE.

Code samples

osc-cli api CreateAccessKey PROFILE \
  --DryRun False \
  --ExpirationDate "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateAccessKey \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "ExpirationDate": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "ExpirationDate": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateAccessKey', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
ExpirationDate string(datetime) false The date and time at which you want the access key to expire, in ISO 8601 format (for example, 2017-06-14 or 2017-06-14T00:00:00Z). If not specified, the access key has no expiration date.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateAccessKeyResponse

Example responses

200 Response

{
  "AccessKey": {
    "AccessKeyId": "string",
    "CreationDate": "string",
    "ExpirationDate": "string",
    "LastModificationDate": "string",
    "SecretKey": "string",
    "State": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteAccessKey

POST /DeleteAccessKey

Deletes the specified access key associated with the account that sends the request.

[NOTE]
To protect against brute force attacks, the number of requests allowed for this method in a given time period is limited.

Code samples

osc-cli api DeleteAccessKey PROFILE \
  --AccessKeyId "string" \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteAccessKey \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "AccessKeyId": "string", \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "AccessKeyId": "string",
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteAccessKey', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
AccessKeyId string true The ID of the access key you want to delete.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteAccessKeyResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadAccessKeys

POST /ReadAccessKeys

Gets information about the access key IDs of a specified user.
If the user does not have any access key ID, this action returns an empty list.

Code samples

osc-cli api ReadAccessKeys PROFILE \
  --DryRun False \
  --Filters '{ \
      "AccessKeyIds": ["string"], \
      "States": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadAccessKeys \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "AccessKeyIds": [ \
      "string" \
    ], \
    "States": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "AccessKeyIds": ["string"], 
    "States": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadAccessKeys', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersAccessKeys false One or more filters.
» AccessKeyIds [string] false The IDs of the access keys.
» States [string] false The states of the access keys (ACTIVE | INACTIVE).

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadAccessKeysResponse

Example responses

200 Response

{
  "AccessKeys": [
    {
      "AccessKeyId": "string",
      "CreationDate": "string",
      "ExpirationDate": "string",
      "LastModificationDate": "string",
      "State": "string"
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadSecretAccessKey

POST /ReadSecretAccessKey

Gets information about the secret access key associated with the account that sends the request.

Code samples

osc-cli api ReadSecretAccessKey PROFILE \
  --AccessKeyId "string" \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadSecretAccessKey \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "AccessKeyId": "string", \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "AccessKeyId": "string",
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadSecretAccessKey', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
AccessKeyId string true The ID of the access key.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadSecretAccessKeyResponse

Example responses

200 Response

{
  "AccessKey": {
    "AccessKeyId": "string",
    "CreationDate": "string",
    "ExpirationDate": "string",
    "LastModificationDate": "string",
    "SecretKey": "string",
    "State": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

UpdateAccessKey

POST /UpdateAccessKey

Modifies the attributes of the specified access key associated with the account that sends the request.

[NOTE]

Code samples

osc-cli api UpdateAccessKey PROFILE \
  --AccessKeyId "string" \
  --DryRun False \
  --ExpirationDate "string" \
  --State "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateAccessKey \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "AccessKeyId": "string", \
  "DryRun": true, \
  "ExpirationDate": "string", \
  "State": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "AccessKeyId": "string",
  "DryRun": False,
  "ExpirationDate": "string",
  "State": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateAccessKey', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
AccessKeyId string true The ID of the access key.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
ExpirationDate string(datetime) false The date and time at which you want the access key to expire, in ISO 8601 format (for example, 2017-06-14 or 2017-06-14T00:00:00Z). If not specified, the access key is set to not expire.
State string true The new state for the access key (ACTIVE | INACTIVE). When set to ACTIVE, the access key is enabled and can be used to send requests. When set to INACTIVE, the access key is disabled.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateAccessKeyResponse

Example responses

200 Response

{
  "AccessKey": {
    "AccessKeyId": "string",
    "CreationDate": "string",
    "ExpirationDate": "string",
    "LastModificationDate": "string",
    "State": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

Account

CheckAuthentication

POST /CheckAuthentication

Validates the authenticity of the account.

Code samples

osc-cli api CheckAuthentication PROFILE \
  --DryRun False \
  --Login "string" \
  --Password "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CheckAuthentication \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Login": "string", \
  "Password": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Login": "string",
  "Password": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CheckAuthentication', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Login string true The email address of the account.
Password string true The password of the account.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CheckAuthenticationResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

CreateAccount

POST /CreateAccount

Creates a new OUTSCALE account.

[NOTE]

Code samples

osc-cli api CreateAccount PROFILE \
  --City "string" \
  --CompanyName "string" \
  --Country "string" \
  --CustomerId "string" \
  --DryRun False \
  --Email "string" \
  --FirstName "string" \
  --JobTitle "string" \
  --LastName "string" \
  --MobileNumber "string" \
  --PhoneNumber "string" \
  --StateProvince "string" \
  --VatNumber "string" \
  --ZipCode "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateAccount \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "City": "string", \
  "CompanyName": "string", \
  "Country": "string", \
  "CustomerId": "string", \
  "DryRun": true, \
  "Email": "string", \
  "FirstName": "string", \
  "JobTitle": "string", \
  "LastName": "string", \
  "MobileNumber": "string", \
  "PhoneNumber": "string", \
  "StateProvince": "string", \
  "VatNumber": "string", \
  "ZipCode": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "City": "string",
  "CompanyName": "string",
  "Country": "string",
  "CustomerId": "string",
  "DryRun": False,
  "Email": "string",
  "FirstName": "string",
  "JobTitle": "string",
  "LastName": "string",
  "MobileNumber": "string",
  "PhoneNumber": "string",
  "StateProvince": "string",
  "VatNumber": "string",
  "ZipCode": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateAccount', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
City string true The city of the account owner.
CompanyName string true The name of the company for the account.
Country string true The country of the account owner.
CustomerId string true The ID of the customer. It must be 8 digits.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Email string true The email address for the account.
FirstName string true The first name of the account owner.
JobTitle string false The job title of the account owner.
LastName string true The last name of the account owner.
MobileNumber string false The mobile phone number of the account owner.
PhoneNumber string false The landline phone number of the account owner.
StateProvince string false The state/province of the account.
VatNumber string false The value added tax (VAT) number for the account.
ZipCode string true The ZIP code of the city.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateAccountResponse

Example responses

200 Response

{
  "Account": {
    "AccountId": "string",
    "City": "string",
    "CompanyName": "string",
    "Country": "string",
    "CustomerId": "string",
    "Email": "string",
    "FirstName": "string",
    "JobTitle": "string",
    "LastName": "string",
    "MobileNumber": "string",
    "PhoneNumber": "string",
    "StateProvince": "string",
    "VatNumber": "string",
    "ZipCode": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadAccounts

POST /ReadAccounts

Gets information about the account that sent the request.

Code samples

osc-cli api ReadAccounts PROFILE \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadAccounts \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadAccounts', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadAccountsResponse

Example responses

200 Response

{
  "Accounts": [
    {
      "AccountId": "string",
      "City": "string",
      "CompanyName": "string",
      "Country": "string",
      "CustomerId": "string",
      "Email": "string",
      "FirstName": "string",
      "JobTitle": "string",
      "LastName": "string",
      "MobileNumber": "string",
      "PhoneNumber": "string",
      "StateProvince": "string",
      "VatNumber": "string",
      "ZipCode": "string"
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadConsumptionAccount

POST /ReadConsumptionAccount

Gets information about the consumption of your account for each billable resource within the specified time period.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the Throttling error message is returned.

Code samples

osc-cli api ReadConsumptionAccount PROFILE \
  --DryRun False \
  --FromDate "string" \
  --ToDate "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadConsumptionAccount \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "FromDate": "string", \
  "ToDate": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "FromDate": "string",
  "ToDate": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadConsumptionAccount', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
FromDate string(datetime) true The beginning of the time period, in ISO 8601 date-time format (for example, 2017-06-14 or 2017-06-14T00:00:00Z).
ToDate string(datetime) true The end of the time period, in ISO 8601 date-time format (for example, 2017-06-30 or 2017-06-30T00:00:00Z).

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadConsumptionAccountResponse

Example responses

200 Response

{
  "ConsumptionEntries": [
    {
      "AccountId": "string",
      "Category": "string",
      "FromDate": "string",
      "Operation": "string",
      "PayingAccountId": "string",
      "Service": "string",
      "SubregionName": "string",
      "Title": "string",
      "ToDate": "string",
      "Type": "string",
      "Value": 0
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

ResetAccountPassword

POST /ResetAccountPassword

Replaces the account password with the new one you provide.
You must also provide the token you received by email when asking for a password reset using the SendResetPasswordEmail method.

Password strength is tested through heuristic algorithms. For more information, see the zxcvbn GitHub.

[NOTE]
To protect against brute force attacks, the number of requests allowed for this method in a given time period is limited.

Code samples

osc-cli api ResetAccountPassword PROFILE \
  --DryRun False \
  --Password "string" \
  --Token "string" 

curl -X POST https://api.{region}.outscale.com/api/v1/ResetAccountPassword \
  -H 'Content-Type: application/json' \
  -d '{ \
  "DryRun": true, \
  "Password": "string", \
  "Token": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}
params = { 
  "DryRun": False,
  "Password": "string",
  "Token": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ResetAccountPassword', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Password string true The new password for the account.
Token string true The token you received at the email address provided for the account.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ResetAccountPasswordResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

SendResetPasswordEmail

POST /SendResetPasswordEmail

Sends an email to the email address provided for the account with a token to reset your password.
You need to provide this token when updating the account password using the ResetAccountPassword method.

[NOTE]
To protect against brute force attacks, the number of requests allowed for this method in a given time period is limited.

Code samples

osc-cli api SendResetPasswordEmail PROFILE \
  --DryRun False \
  --Email "string" 

curl -X POST https://api.{region}.outscale.com/api/v1/SendResetPasswordEmail \
  -H 'Content-Type: application/json' \
  -d '{ \
  "DryRun": true, \
  "Email": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}
params = { 
  "DryRun": False,
  "Email": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/SendResetPasswordEmail', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Email string true The email address provided for the account.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK).You need to provide this token when updating the account password using the ResetAccountPassword method. SendResetPasswordEmailResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

UpdateAccount

POST /UpdateAccount

Updates the account information for the account that sends the request.

Code samples

osc-cli api UpdateAccount PROFILE \
  --City "string" \
  --CompanyName "string" \
  --Country "string" \
  --DryRun False \
  --Email "string" \
  --FirstName "string" \
  --JobTitle "string" \
  --LastName "string" \
  --MobileNumber "string" \
  --PhoneNumber "string" \
  --StateProvince "string" \
  --VatNumber "string" \
  --ZipCode "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateAccount \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "City": "string", \
  "CompanyName": "string", \
  "Country": "string", \
  "DryRun": true, \
  "Email": "string", \
  "FirstName": "string", \
  "JobTitle": "string", \
  "LastName": "string", \
  "MobileNumber": "string", \
  "PhoneNumber": "string", \
  "StateProvince": "string", \
  "VatNumber": "string", \
  "ZipCode": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "City": "string",
  "CompanyName": "string",
  "Country": "string",
  "DryRun": False,
  "Email": "string",
  "FirstName": "string",
  "JobTitle": "string",
  "LastName": "string",
  "MobileNumber": "string",
  "PhoneNumber": "string",
  "StateProvince": "string",
  "VatNumber": "string",
  "ZipCode": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateAccount', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
City string false The new city of the account owner.
CompanyName string false The new name of the company for the account.
Country string false The new country of the account owner.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Email string false The new email address for the account.
FirstName string false The new first name of the account owner.
JobTitle string false The new job title of the account owner.
LastName string false The new last name of the account owner.
MobileNumber string false The new mobile phone number of the account owner.
PhoneNumber string false The new landline phone number of the account owner.
StateProvince string false The new state/province of the account owner.
VatNumber string false The new value added tax (VAT) number for the account.
ZipCode string false The new ZIP code of the city.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateAccountResponse

Example responses

200 Response

{
  "Account": {
    "AccountId": "string",
    "City": "string",
    "CompanyName": "string",
    "Country": "string",
    "CustomerId": "string",
    "Email": "string",
    "FirstName": "string",
    "JobTitle": "string",
    "LastName": "string",
    "MobileNumber": "string",
    "PhoneNumber": "string",
    "StateProvince": "string",
    "VatNumber": "string",
    "ZipCode": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

ApiAccessPolicy

ReadApiAccessPolicy

POST /ReadApiAccessPolicy

Gets information about the API access policy of your account.

Code samples

osc-cli api ReadApiAccessPolicy PROFILE \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadApiAccessPolicy \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadApiAccessPolicy', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadApiAccessPolicyResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ApiAccessPolicy": {
    "MaxAccessKeyExpirationSeconds": 0,
    "RequireTrustedEnv": true
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

UpdateApiAccessPolicy

POST /UpdateApiAccessPolicy

Updates the API access policy of your account.

[NOTE]
Only one API access policy can be associated with your account.

Code samples

osc-cli api UpdateApiAccessPolicy PROFILE \
  --DryRun False \
  --MaxAccessKeyExpirationSeconds 0 \
  --RequireTrustedEnv True 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateApiAccessPolicy \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "MaxAccessKeyExpirationSeconds": 0, \
  "RequireTrustedEnv": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "MaxAccessKeyExpirationSeconds": 0,
  "RequireTrustedEnv": True
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateApiAccessPolicy', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
MaxAccessKeyExpirationSeconds integer(int64) true The maximum possible lifetime for your access keys, in seconds (between 0 and 3153600000, both included). By default or if set to O, your access keys can have unlimited lifetimes. Otherwise, all your access keys must have an expiration date. This value must be greater than the remaining lifetime of each access key of your account.
RequireTrustedEnv boolean true If true, a trusted session is activated, provided that you specify the MaxAccessKeyExpirationSeconds parameter with a value greater than 0.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateApiAccessPolicyResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ApiAccessPolicy": {
    "MaxAccessKeyExpirationSeconds": 0,
    "RequireTrustedEnv": true
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

ApiAccessRule

CreateApiAccessRule

POST /CreateApiAccessRule

Creates a rule to allow access to the API from your account.
You need to specify at least the CaIds or the IpRanges parameter.

[NOTE]
By default, your account has a set of rules allowing global access that you can delete. For more information, see About API Access Rules.

Code samples

osc-cli api CreateApiAccessRule PROFILE \
  --CaIds '["string"]' \
  --Cns '["string"]' \
  --Description "string" \
  --DryRun False \
  --IpRanges '["string"]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateApiAccessRule \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "CaIds": [ \
    "string" \
  ], \
  "Cns": [ \
    "string" \
  ], \
  "Description": "string", \
  "DryRun": true, \
  "IpRanges": [ \
    "string" \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "CaIds": ["string"],
  "Cns": ["string"],
  "Description": "string",
  "DryRun": False,
  "IpRanges": ["string"]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateApiAccessRule', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
CaIds [string] false One or more IDs of Client Certificate Authorities (CAs).
Cns [string] false One or more Client Certificate Common Names (CNs). If this parameter is specified, you must also specify the CaIds parameter.
Description string false A description for the API access rule.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
IpRanges [string] false One or more IP ranges, in CIDR notation (for example, 192.0.2.0/16).

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateApiAccessRuleResponse

Example responses

200 Response

{
  "ApiAccessRule": {
    "ApiAccessRuleId": "string",
    "CaIds": [
      "string"
    ],
    "Cns": [
      "string"
    ],
    "Description": "string",
    "IpRanges": [
      "string"
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteApiAccessRule

POST /DeleteApiAccessRule

Deletes a specified API access rule.

[NOTE]
You cannot delete the last remaining API access rule. However, if you delete all the API access rules that allow you to access the API, you need to contact the Support team to regain access. For more information, see Technical Support.

Code samples

osc-cli api DeleteApiAccessRule PROFILE \
  --ApiAccessRuleId "string" \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteApiAccessRule \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "ApiAccessRuleId": "string", \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "ApiAccessRuleId": "string",
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteApiAccessRule', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
ApiAccessRuleId string true The ID of the API access rule you want to delete.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteApiAccessRuleResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadApiAccessRules

POST /ReadApiAccessRules

Lists one or more API access rules.

Code samples

osc-cli api ReadApiAccessRules PROFILE \
  --DryRun False \
  --Filters '{ \
      "ApiAccessRuleIds": ["string"], \
      "CaIds": ["string"], \
      "Cns": ["string"], \
      "Descriptions": ["string"], \
      "IpRanges": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadApiAccessRules \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "ApiAccessRuleIds": [ \
      "string" \
    ], \
    "CaIds": [ \
      "string" \
    ], \
    "Cns": [ \
      "string" \
    ], \
    "Descriptions": [ \
      "string" \
    ], \
    "IpRanges": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "ApiAccessRuleIds": ["string"], 
    "CaIds": ["string"], 
    "Cns": ["string"], 
    "Descriptions": ["string"], 
    "IpRanges": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadApiAccessRules', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersApiAccessRule false One or more filters.
» ApiAccessRuleIds [string] false One or more IDs of API access rules.
» CaIds [string] false One or more IDs of Client Certificate Authorities (CAs).
» Cns [string] false One or more Client Certificate Common Names (CNs).
» Descriptions [string] false One or more descriptions of API access rules.
» IpRanges [string] false One or more IP ranges, in CIDR notation (for example, 192.0.2.0/16).

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadApiAccessRulesResponse

Example responses

200 Response

{
  "ApiAccessRules": [
    {
      "ApiAccessRuleId": "string",
      "CaIds": [
        "string"
      ],
      "Cns": [
        "string"
      ],
      "Description": "string",
      "IpRanges": [
        "string"
      ]
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

UpdateApiAccessRule

POST /UpdateApiAccessRule

Modifies a specified API access rule.

[NOTE]
The new rule you specify fully replaces the old rule. Therefore, for a parameter that is not specified, any previously set value is deleted.

Code samples

osc-cli api UpdateApiAccessRule PROFILE \
  --ApiAccessRuleId "string" \
  --CaIds '["string"]' \
  --Cns '["string"]' \
  --Description "string" \
  --DryRun False \
  --IpRanges '["string"]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateApiAccessRule \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "ApiAccessRuleId": "string", \
  "CaIds": [ \
    "string" \
  ], \
  "Cns": [ \
    "string" \
  ], \
  "Description": "string", \
  "DryRun": true, \
  "IpRanges": [ \
    "string" \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "ApiAccessRuleId": "string",
  "CaIds": ["string"],
  "Cns": ["string"],
  "Description": "string",
  "DryRun": False,
  "IpRanges": ["string"]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateApiAccessRule', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
ApiAccessRuleId string true The ID of the API access rule you want to update.
CaIds [string] false One or more IDs of Client Certificate Authorities (CAs).
Cns [string] false One or more Client Certificate Common Names (CNs).
Description string false A new description for the API access rule.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
IpRanges [string] false One or more IP ranges, in CIDR notation (for example, 192.0.2.0/16).

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateApiAccessRuleResponse

Example responses

200 Response

{
  "ApiAccessRule": {
    "ApiAccessRuleId": "string",
    "CaIds": [
      "string"
    ],
    "Cns": [
      "string"
    ],
    "Description": "string",
    "IpRanges": [
      "string"
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

ApiLog

ReadApiLogs

POST /ReadApiLogs

Lists the logs of the API calls you have performed with this account. Past logs are accessible for up to 30 days. For more information, see About OUTSCALE Monitoring Services (OMS).

Code samples

osc-cli api ReadApiLogs PROFILE \
  --DryRun False \
  --Filters '{ \
      "QueryAccessKeys": ["string"], \
      "QueryApiNames": ["string"], \
      "QueryCallNames": ["string"], \
      "QueryIpAddresses": ["string"], \
      "QueryUserAgents": ["string"], \
      "RequestIds": ["string"], \
      "ResponseStatusCodes": [0] \
    }' \
  --NextPageToken "string" \
  --ResultsPerPage 0 \
  --With '{ \
      "AccountId": True, \
      "CallDuration": True, \
      "QueryAccessKey": True, \
      "QueryApiName": True, \
      "QueryApiVersion": True, \
      "QueryCallName": True, \
      "QueryDate": True, \
      "QueryHeaderRaw": True, \
      "QueryHeaderSize": True, \
      "QueryIpAddress": True, \
      "QueryPayloadRaw": True, \
      "QueryPayloadSize": True, \
      "QueryUserAgent": True, \
      "RequestId": True, \
      "ResponseSize": True, \
      "ResponseStatusCode": True \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadApiLogs \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "QueryAccessKeys": [ \
      "string" \
    ], \
    "QueryApiNames": [ \
      "string" \
    ], \
    "QueryCallNames": [ \
      "string" \
    ], \
    "QueryIpAddresses": [ \
      "string" \
    ], \
    "QueryUserAgents": [ \
      "string" \
    ], \
    "RequestIds": [ \
      "string" \
    ], \
    "ResponseStatusCodes": [ \
      0 \
    ] \
  }, \
  "NextPageToken": "string", \
  "ResultsPerPage": 0, \
  "With": { \
    "AccountId": true, \
    "CallDuration": true, \
    "QueryAccessKey": true, \
    "QueryApiName": true, \
    "QueryApiVersion": true, \
    "QueryCallName": true, \
    "QueryDate": true, \
    "QueryHeaderRaw": true, \
    "QueryHeaderSize": true, \
    "QueryIpAddress": true, \
    "QueryPayloadRaw": true, \
    "QueryPayloadSize": true, \
    "QueryUserAgent": true, \
    "RequestId": true, \
    "ResponseSize": true, \
    "ResponseStatusCode": true \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "QueryAccessKeys": ["string"], 
    "QueryApiNames": ["string"], 
    "QueryCallNames": ["string"], 
    "QueryIpAddresses": ["string"], 
    "QueryUserAgents": ["string"], 
    "RequestIds": ["string"], 
    "ResponseStatusCodes": [0] 
  },
  "NextPageToken": "string",
  "ResultsPerPage": 0,
  "With": { 
    "AccountId": True, 
    "CallDuration": True, 
    "QueryAccessKey": True, 
    "QueryApiName": True, 
    "QueryApiVersion": True, 
    "QueryCallName": True, 
    "QueryDate": True, 
    "QueryHeaderRaw": True, 
    "QueryHeaderSize": True, 
    "QueryIpAddress": True, 
    "QueryPayloadRaw": True, 
    "QueryPayloadSize": True, 
    "QueryUserAgent": True, 
    "RequestId": True, 
    "ResponseSize": True, 
    "ResponseStatusCode": True 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadApiLogs', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersApiLog false One or more filters.
» QueryAccessKeys [string] false The access keys used for the logged calls.
» QueryApiNames [string] false The names of the APIs of the logged calls (always oapi for the OUTSCALE API).
» QueryCallNames [string] false The names of the logged calls.
» QueryIpAddresses [string] false The IPs used for the logged calls.
» QueryUserAgents [string] false The user agents of the HTTP requests of the logged calls.
» RequestIds [string] false The request IDs provided in the responses of the logged calls.
» ResponseStatusCodes [integer] false The HTTP status codes of the logged calls.
NextPageToken string false The token to request the next page of results.
ResultsPerPage integer false The maximum number of logs returned in a single response (between 1and 1000, both included). By default, 100.
With With false The information to display in each returned log. If this parameter is not specified, all available fields are considered as true.
» AccountId boolean false By default or if set to true, the account ID is displayed.
» CallDuration boolean false If set to true, the duration of the call is displayed.
» QueryAccessKey boolean false If set to true, the access key is displayed.
» QueryApiName boolean false If set to true, the name of the API is displayed.
» QueryApiVersion boolean false If set to true, the version of the API is displayed.
» QueryCallName boolean false If set to true, the name of the call is displayed.
» QueryDate boolean false If set to true, the date of the call is displayed.
» QueryHeaderRaw boolean false If set to true, the raw header of the HTTP request is displayed.
» QueryHeaderSize boolean false If set to true, the size of the raw header of the HTTP request is displayed.
» QueryIpAddress boolean false If set to true, the IP is displayed.
» QueryPayloadRaw boolean false If set to true, the raw payload of the HTTP request is displayed.
» QueryPayloadSize boolean false If set to true, the size of the raw payload of the HTTP request is displayed.
» QueryUserAgent boolean false If set to true, the user agent of the HTTP request is displayed.
» RequestId boolean false By default ot if set to true, the request ID is displayed.
» ResponseSize boolean false If set to true, the size of the response is displayed.
» ResponseStatusCode boolean false If set to true, the HTTP status code of the response is displayed.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadApiLogsResponse

Example responses

200 Response

{
  "Logs": [
    {
      "AccountId": "string",
      "CallDuration": 0,
      "QueryAccessKey": "string",
      "QueryApiName": "string",
      "QueryApiVersion": "string",
      "QueryCallName": "string",
      "QueryDate": "2019-08-24",
      "QueryHeaderRaw": "string",
      "QueryHeaderSize": 0,
      "QueryIpAddress": "string",
      "QueryPayloadRaw": "string",
      "QueryPayloadSize": 0,
      "QueryUserAgent": "string",
      "RequestId": "string",
      "ResponseSize": 0,
      "ResponseStatusCode": 0
    }
  ],
  "NextPageToken": "string",
  "ResponseContext": {
    "RequestId": "string"
  }
}

Ca

CreateCa

POST /CreateCa

Creates a Client Certificate Authority (CA).

Code samples

osc-cli api CreateCa PROFILE \
  --CaPem "string" \
  --Description "string" \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateCa \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "CaPem": "string", \
  "Description": "string", \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "CaPem": "string",
  "Description": "string",
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateCa', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
CaPem string true The CA in PEM format.
Description string false The description of the CA.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateCaResponse

Example responses

200 Response

{
  "Ca": {
    "CaFingerprint": "string",
    "CaId": "string",
    "Description": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteCa

POST /DeleteCa

Deletes a specified Client Certificate Authority (CA).

Code samples

osc-cli api DeleteCa PROFILE \
  --CaId "string" \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteCa \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "CaId": "string", \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "CaId": "string",
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteCa', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
CaId string true The ID of the CA you want to delete.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteCaResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadCas

POST /ReadCas

Gets information about one or more of your Client Certificate Authorities (CAs).

Code samples

osc-cli api ReadCas PROFILE \
  --DryRun False \
  --Filters '{ \
      "CaFingerprints": ["string"], \
      "CaIds": ["string"], \
      "Descriptions": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadCas \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "CaFingerprints": [ \
      "string" \
    ], \
    "CaIds": [ \
      "string" \
    ], \
    "Descriptions": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "CaFingerprints": ["string"], 
    "CaIds": ["string"], 
    "Descriptions": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadCas', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersCa false One or more filters.
» CaFingerprints [string] false The fingerprints of the CAs.
» CaIds [string] false The IDs of the CAs.
» Descriptions [string] false The descriptions of the CAs.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadCasResponse

Example responses

200 Response

{
  "Cas": [
    {
      "CaFingerprint": "string",
      "CaId": "string",
      "Description": "string"
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

UpdateCa

POST /UpdateCa

Modifies the specified attribute of a Client Certificate Authority (CA).

Code samples

osc-cli api UpdateCa PROFILE \
  --CaId "string" \
  --Description "string" \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateCa \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "CaId": "string", \
  "Description": "string", \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "CaId": "string",
  "Description": "string",
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateCa', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
CaId string true The ID of the CA.
Description string false The description of the CA.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateCaResponse

Example responses

200 Response

{
  "Ca": {
    "CaFingerprint": "string",
    "CaId": "string",
    "Description": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

ClientGateway

CreateClientGateway

POST /CreateClientGateway

Provides information about your client gateway.
This action registers information to identify the client gateway that you deployed in your network.
To open a tunnel to the client gateway, you must provide the communication protocol type, the fixed public IP of the gateway, and an Autonomous System Number (ASN).

Code samples

osc-cli api CreateClientGateway PROFILE \
  --BgpAsn 0 \
  --ConnectionType "string" \
  --DryRun False \
  --PublicIp "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateClientGateway \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "BgpAsn": 0, \
  "ConnectionType": "string", \
  "DryRun": true, \
  "PublicIp": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "BgpAsn": 0,
  "ConnectionType": "string",
  "DryRun": False,
  "PublicIp": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateClientGateway', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
BgpAsn integer true An Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find the path to your client gateway through the Internet.
ConnectionType string true The communication protocol used to establish tunnel with your client gateway (only ipsec.1 is supported).
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
PublicIp string true The public fixed IPv4 address of your client gateway.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateClientGatewayResponse

Example responses

200 Response

{
  "ClientGateway": {
    "BgpAsn": 0,
    "ClientGatewayId": "string",
    "ConnectionType": "string",
    "PublicIp": "string",
    "State": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteClientGateway

POST /DeleteClientGateway

Deletes a client gateway.
You must delete the VPN connection before deleting the client gateway.

Code samples

osc-cli api DeleteClientGateway PROFILE \
  --ClientGatewayId "string" \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteClientGateway \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "ClientGatewayId": "string", \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "ClientGatewayId": "string",
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteClientGateway', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
ClientGatewayId string true The ID of the client gateway you want to delete.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteClientGatewayResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadClientGateways

POST /ReadClientGateways

Lists one or more of your client gateways.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadClientGateways PROFILE \
  --DryRun False \
  --Filters '{ \
      "BgpAsns": [0], \
      "ClientGatewayIds": ["string"], \
      "ConnectionTypes": ["string"], \
      "PublicIps": ["string"], \
      "States": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadClientGateways \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "BgpAsns": [ \
      0 \
    ], \
    "ClientGatewayIds": [ \
      "string" \
    ], \
    "ConnectionTypes": [ \
      "string" \
    ], \
    "PublicIps": [ \
      "string" \
    ], \
    "States": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "BgpAsns": [0], 
    "ClientGatewayIds": ["string"], 
    "ConnectionTypes": ["string"], 
    "PublicIps": ["string"], 
    "States": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadClientGateways', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersClientGateway false One or more filters.
» BgpAsns [integer] false The Border Gateway Protocol (BGP) Autonomous System Numbers (ASNs) of the connections.
» ClientGatewayIds [string] false The IDs of the client gateways.
» ConnectionTypes [string] false The types of communication tunnels used by the client gateways (only ipsec.1 is supported).
» PublicIps [string] false The public IPv4 addresses of the client gateways.
» States [string] false The states of the client gateways (pending | available | deleting | deleted).
» TagKeys [string] false The keys of the tags associated with the client gateways.
» TagValues [string] false The values of the tags associated with the client gateways.
» Tags [string] false The key/value combination of the tags associated with the client gateways, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadClientGatewaysResponse

Example responses

200 Response

{
  "ClientGateways": [
    {
      "BgpAsn": 0,
      "ClientGatewayId": "string",
      "ConnectionType": "string",
      "PublicIp": "string",
      "State": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ]
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

DhcpOption

CreateDhcpOptions

POST /CreateDhcpOptions

Creates a new set of DHCP options, that you can then associate with a Net using the UpdateNet method.

Code samples

osc-cli api CreateDhcpOptions PROFILE \
  --DomainName "string" \
  --DomainNameServers '["string"]' \
  --DryRun False \
  --NtpServers '["string"]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateDhcpOptions \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DomainName": "string", \
  "DomainNameServers": [ \
    "string" \
  ], \
  "DryRun": true, \
  "NtpServers": [ \
    "string" \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DomainName": "string",
  "DomainNameServers": ["string"],
  "DryRun": False,
  "NtpServers": ["string"]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateDhcpOptions', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DomainName string false Specify a domain name (for example, MyCompany.com). You can specify only one domain name.
DomainNameServers [string] false The IPs of domain name servers. If no IPs are specified, the OutscaleProvidedDNS value is set by default.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NtpServers [string] false The IPs of the Network Time Protocol (NTP) servers.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateDhcpOptionsResponse

Example responses

200 Response

{
  "DhcpOptionsSet": {
    "Default": true,
    "DhcpOptionsSetId": "string",
    "DomainName": "string",
    "DomainNameServers": [
      "string"
    ],
    "NtpServers": [
      "string"
    ],
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteDhcpOptions

POST /DeleteDhcpOptions

Deletes a specified DHCP options set.
Before deleting a DHCP options set, you must disassociate it from the Nets you associated it with. To do so, you need to associate with each Net a new set of DHCP options, or the default one if you do not want to associate any DHCP options with the Net.

[NOTE]
You cannot delete the default set.

Code samples

osc-cli api DeleteDhcpOptions PROFILE \
  --DhcpOptionsSetId "string" \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteDhcpOptions \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DhcpOptionsSetId": "string", \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DhcpOptionsSetId": "string",
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteDhcpOptions', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DhcpOptionsSetId string true The ID of the DHCP options set you want to delete.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteDhcpOptionsResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadDhcpOptions

POST /ReadDhcpOptions

Gets information about the content of one or more DHCP options sets.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadDhcpOptions PROFILE \
  --DryRun False \
  --Filters '{ \
      "Default": True, \
      "DhcpOptionsSetIds": ["string"], \
      "DomainNameServers": ["string"], \
      "DomainNames": ["string"], \
      "NtpServers": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadDhcpOptions \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "Default": true, \
    "DhcpOptionsSetIds": [ \
      "string" \
    ], \
    "DomainNameServers": [ \
      "string" \
    ], \
    "DomainNames": [ \
      "string" \
    ], \
    "NtpServers": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "Default": True, 
    "DhcpOptionsSetIds": ["string"], 
    "DomainNameServers": ["string"], 
    "DomainNames": ["string"], 
    "NtpServers": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadDhcpOptions', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersDhcpOptions false One or more filters.
» Default boolean false If true, lists all default DHCP options set. If false, lists all non-default DHCP options set.
» DhcpOptionsSetIds [string] false The IDs of the DHCP options sets.
» DomainNameServers [string] false The domain name servers used for the DHCP options sets.
» DomainNames [string] false The domain names used for the DHCP options sets.
» NtpServers [string] false The Network Time Protocol (NTP) servers used for the DHCP options sets.
» TagKeys [string] false The keys of the tags associated with the DHCP options sets.
» TagValues [string] false The values of the tags associated with the DHCP options sets.
» Tags [string] false The key/value combination of the tags associated with the DHCP options sets, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadDhcpOptionsResponse

Example responses

200 Response

{
  "DhcpOptionsSets": [
    {
      "Default": true,
      "DhcpOptionsSetId": "string",
      "DomainName": "string",
      "DomainNameServers": [
        "string"
      ],
      "NtpServers": [
        "string"
      ],
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ]
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

DirectLink

POST /CreateDirectLink

Creates a new DirectLink between a customer network and a specified DirectLink location.

Code samples

osc-cli api CreateDirectLink PROFILE \
  --Bandwidth "string" \
  --DirectLinkName "string" \
  --DryRun False \
  --Location "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateDirectLink \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "Bandwidth": "string", \
  "DirectLinkName": "string", \
  "DryRun": true, \
  "Location": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "Bandwidth": "string",
  "DirectLinkName": "string",
  "DryRun": False,
  "Location": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateDirectLink', headers = headers, json = params)
print(r.json())

Parameter Type Required Description
Bandwidth string true The bandwidth of the DirectLink (1Gbps | 10Gbps).
DirectLinkName string true The name of the DirectLink.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Location string true The code of the requested location for the DirectLink, returned by the ReadLocations method.
Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateDirectLinkResponse

Example responses

200 Response

{
  "DirectLink": {
    "AccountId": "string",
    "Bandwidth": "string",
    "DirectLinkId": "string",
    "DirectLinkName": "string",
    "Location": "string",
    "RegionName": "string",
    "State": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

POST /DeleteDirectLink

Deletes a specified DirectLink.
Before deleting a DirectLink, ensure that all your DirectLink interfaces related to this DirectLink are deleted.

Code samples

osc-cli api DeleteDirectLink PROFILE \
  --DirectLinkId "string" \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteDirectLink \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DirectLinkId": "string", \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DirectLinkId": "string",
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteDirectLink', headers = headers, json = params)
print(r.json())

Parameter Type Required Description
DirectLinkId string true The ID of the DirectLink you want to delete.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteDirectLinkResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

POST /ReadDirectLinks

Lists all DirectLinks in the Region.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the Throttling error message is returned.

Code samples

osc-cli api ReadDirectLinks PROFILE \
  --DryRun False \
  --Filters '{ \
      "DirectLinkIds": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadDirectLinks \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "DirectLinkIds": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "DirectLinkIds": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadDirectLinks', headers = headers, json = params)
print(r.json())

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersDirectLink false One or more filters.
» DirectLinkIds [string] false The IDs of the DirectLinks.
Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadDirectLinksResponse

Example responses

200 Response

{
  "DirectLinks": [
    {
      "AccountId": "string",
      "Bandwidth": "string",
      "DirectLinkId": "string",
      "DirectLinkName": "string",
      "Location": "string",
      "RegionName": "string",
      "State": "string"
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

DirectLinkInterface

CreateDirectLinkInterface

POST /CreateDirectLinkInterface

Creates a DirectLink interface.
DirectLink interfaces enable you to reach one of your Nets through a virtual gateway.

Code samples

osc-cli api CreateDirectLinkInterface PROFILE \
  --DirectLinkId "string" \
  --DirectLinkInterface '{ \
      "BgpAsn": 0, \
      "BgpKey": "string", \
      "ClientPrivateIp": "string", \
      "DirectLinkInterfaceName": "string", \
      "OutscalePrivateIp": "string", \
      "VirtualGatewayId": "string", \
      "Vlan": 0 \
    }' \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateDirectLinkInterface \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DirectLinkId": "string", \
  "DirectLinkInterface": { \
    "BgpAsn": 0, \
    "BgpKey": "string", \
    "ClientPrivateIp": "string", \
    "DirectLinkInterfaceName": "string", \
    "OutscalePrivateIp": "string", \
    "VirtualGatewayId": "string", \
    "Vlan": 0 \
  }, \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DirectLinkId": "string",
  "DirectLinkInterface": { 
    "BgpAsn": 0, 
    "BgpKey": "string", 
    "ClientPrivateIp": "string", 
    "DirectLinkInterfaceName": "string", 
    "OutscalePrivateIp": "string", 
    "VirtualGatewayId": "string", 
    "Vlan": 0 
  },
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateDirectLinkInterface', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DirectLinkId string true The ID of the existing DirectLink for which you want to create the DirectLink interface.
DirectLinkInterface DirectLinkInterface true Information about the DirectLink interface.
» BgpAsn integer true The BGP (Border Gateway Protocol) ASN (Autonomous System Number) on the customer's side of the DirectLink interface.
» BgpKey string false The BGP authentication key.
» ClientPrivateIp string false The IP on the customer's side of the DirectLink interface.
» DirectLinkInterfaceName string true The name of the DirectLink interface.
» OutscalePrivateIp string false The IP on the OUTSCALE side of the DirectLink interface.
» VirtualGatewayId string true The ID of the target virtual gateway.
» Vlan integer true The VLAN number associated with the DirectLink interface.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateDirectLinkInterfaceResponse

Example responses

200 Response

{
  "DirectLinkInterface": {
    "AccountId": "string",
    "BgpAsn": 0,
    "BgpKey": "string",
    "ClientPrivateIp": "string",
    "DirectLinkId": "string",
    "DirectLinkInterfaceId": "string",
    "DirectLinkInterfaceName": "string",
    "InterfaceType": "string",
    "Location": "string",
    "OutscalePrivateIp": "string",
    "State": "string",
    "VirtualGatewayId": "string",
    "Vlan": 0
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteDirectLinkInterface

POST /DeleteDirectLinkInterface

Deletes a specified DirectLink interface.

Code samples

osc-cli api DeleteDirectLinkInterface PROFILE \
  --DirectLinkInterfaceId "string" \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteDirectLinkInterface \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DirectLinkInterfaceId": "string", \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DirectLinkInterfaceId": "string",
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteDirectLinkInterface', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DirectLinkInterfaceId string true The ID of the DirectLink interface you want to delete.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteDirectLinkInterfaceResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadDirectLinkInterfaces

POST /ReadDirectLinkInterfaces

Lists one or more of your DirectLink interfaces.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the Throttling error message is returned.

Code samples

osc-cli api ReadDirectLinkInterfaces PROFILE \
  --DryRun False \
  --Filters '{ \
      "DirectLinkIds": ["string"], \
      "DirectLinkInterfaceIds": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadDirectLinkInterfaces \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "DirectLinkIds": [ \
      "string" \
    ], \
    "DirectLinkInterfaceIds": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "DirectLinkIds": ["string"], 
    "DirectLinkInterfaceIds": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadDirectLinkInterfaces', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersDirectLinkInterface false One or more filters.
» DirectLinkIds [string] false The IDs of the DirectLinks.
» DirectLinkInterfaceIds [string] false The IDs of the DirectLink interfaces.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadDirectLinkInterfacesResponse

Example responses

200 Response

{
  "DirectLinkInterfaces": [
    {
      "AccountId": "string",
      "BgpAsn": 0,
      "BgpKey": "string",
      "ClientPrivateIp": "string",
      "DirectLinkId": "string",
      "DirectLinkInterfaceId": "string",
      "DirectLinkInterfaceName": "string",
      "InterfaceType": "string",
      "Location": "string",
      "OutscalePrivateIp": "string",
      "State": "string",
      "VirtualGatewayId": "string",
      "Vlan": 0
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

FlexibleGpu

CreateFlexibleGpu

POST /CreateFlexibleGpu

Allocates a flexible GPU (fGPU) to your account.
You can then attach this fGPU to a virtual machine (VM).

Code samples

osc-cli api CreateFlexibleGpu PROFILE \
  --DeleteOnVmDeletion False \
  --DryRun False \
  --Generation "string" \
  --ModelName "string" \
  --SubregionName "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateFlexibleGpu \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DeleteOnVmDeletion": false, \
  "DryRun": true, \
  "Generation": "string", \
  "ModelName": "string", \
  "SubregionName": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DeleteOnVmDeletion": False,
  "DryRun": False,
  "Generation": "string",
  "ModelName": "string",
  "SubregionName": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateFlexibleGpu', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DeleteOnVmDeletion boolean false If true, the fGPU is deleted when the VM is terminated.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Generation string false The processor generation that the fGPU must be compatible with. If not specified, the oldest possible processor generation is selected (as provided by ReadFlexibleGpuCatalog for the specified model of fGPU).
ModelName string true The model of fGPU you want to allocate. For more information, see About Flexible GPUs.
SubregionName string true The Subregion in which you want to create the fGPU.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateFlexibleGpuResponse

Example responses

200 Response

{
  "FlexibleGpu": {
    "DeleteOnVmDeletion": true,
    "FlexibleGpuId": "string",
    "Generation": "string",
    "ModelName": "string",
    "State": "string",
    "SubregionName": "string",
    "VmId": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteFlexibleGpu

POST /DeleteFlexibleGpu

Releases a flexible GPU (fGPU) from your account.
The fGPU becomes free to be used by someone else.

Code samples

osc-cli api DeleteFlexibleGpu PROFILE \
  --DryRun False \
  --FlexibleGpuId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteFlexibleGpu \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "FlexibleGpuId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "FlexibleGpuId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteFlexibleGpu', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
FlexibleGpuId string true The ID of the fGPU you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteFlexibleGpuResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

LinkFlexibleGpu

POST /LinkFlexibleGpu

Attaches one of your allocated flexible GPUs (fGPUs) to one of your virtual machines (VMs).
The fGPU is in the attaching state until the VM is stopped, after which it becomes attached.

Code samples

osc-cli api LinkFlexibleGpu PROFILE \
  --DryRun False \
  --FlexibleGpuId "string" \
  --VmId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/LinkFlexibleGpu \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "FlexibleGpuId": "string", \
  "VmId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "FlexibleGpuId": "string",
  "VmId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/LinkFlexibleGpu', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
FlexibleGpuId string true The ID of the fGPU you want to attach.
VmId string true The ID of the VM you want to attach the fGPU to.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). LinkFlexibleGpuResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadFlexibleGpuCatalog

POST /ReadFlexibleGpuCatalog

Lists all flexible GPUs available in the public catalog.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadFlexibleGpuCatalog PROFILE \
  --DryRun False 

curl -X POST https://api.{region}.outscale.com/api/v1/ReadFlexibleGpuCatalog \
  -H 'Content-Type: application/json' \
  -d '{ \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}
params = { 
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadFlexibleGpuCatalog', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadFlexibleGpuCatalogResponse

Example responses

200 Response

{
  "FlexibleGpuCatalog": [
    {
      "Generations": [
        "string"
      ],
      "MaxCpu": 0,
      "MaxRam": 0,
      "ModelName": "string",
      "VRam": 0
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadFlexibleGpus

POST /ReadFlexibleGpus

Lists one or more flexible GPUs (fGPUs) allocated to your account.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadFlexibleGpus PROFILE \
  --DryRun False \
  --Filters '{ \
      "DeleteOnVmDeletion": True, \
      "FlexibleGpuIds": ["string"], \
      "Generations": ["string"], \
      "ModelNames": ["string"], \
      "States": ["string"], \
      "SubregionNames": ["string"], \
      "VmIds": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadFlexibleGpus \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "DeleteOnVmDeletion": true, \
    "FlexibleGpuIds": [ \
      "string" \
    ], \
    "Generations": [ \
      "string" \
    ], \
    "ModelNames": [ \
      "string" \
    ], \
    "States": [ \
      "string" \
    ], \
    "SubregionNames": [ \
      "string" \
    ], \
    "VmIds": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "DeleteOnVmDeletion": True, 
    "FlexibleGpuIds": ["string"], 
    "Generations": ["string"], 
    "ModelNames": ["string"], 
    "States": ["string"], 
    "SubregionNames": ["string"], 
    "VmIds": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadFlexibleGpus', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersFlexibleGpu false One or more filters.
» DeleteOnVmDeletion boolean false Indicates whether the fGPU is deleted when terminating the VM.
» FlexibleGpuIds [string] false One or more IDs of fGPUs.
» Generations [string] false The processor generations that the fGPUs are compatible with.
» ModelNames [string] false One or more models of fGPUs. For more information, see About Flexible GPUs.
» States [string] false The states of the fGPUs (allocated | attaching | attached | detaching).
» SubregionNames [string] false The Subregions where the fGPUs are located.
» VmIds [string] false One or more IDs of VMs.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadFlexibleGpusResponse

Example responses

200 Response

{
  "FlexibleGpus": [
    {
      "DeleteOnVmDeletion": true,
      "FlexibleGpuId": "string",
      "Generation": "string",
      "ModelName": "string",
      "State": "string",
      "SubregionName": "string",
      "VmId": "string"
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

UnlinkFlexibleGpu

POST /UnlinkFlexibleGpu

Detaches a flexible GPU (fGPU) from a virtual machine (VM).
The fGPU is in the detaching state until the VM is stopped, after which it becomes available for allocation again.

Code samples

osc-cli api UnlinkFlexibleGpu PROFILE \
  --DryRun False \
  --FlexibleGpuId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UnlinkFlexibleGpu \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "FlexibleGpuId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "FlexibleGpuId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UnlinkFlexibleGpu', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
FlexibleGpuId string true The ID of the fGPU you want to detach from your VM.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UnlinkFlexibleGpuResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

UpdateFlexibleGpu

POST /UpdateFlexibleGpu

Modifies a flexible GPU (fGPU) behavior.

Code samples

osc-cli api UpdateFlexibleGpu PROFILE \
  --DeleteOnVmDeletion True \
  --DryRun False \
  --FlexibleGpuId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateFlexibleGpu \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DeleteOnVmDeletion": true, \
  "DryRun": true, \
  "FlexibleGpuId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DeleteOnVmDeletion": True,
  "DryRun": False,
  "FlexibleGpuId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateFlexibleGpu', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DeleteOnVmDeletion boolean false If true, the fGPU is deleted when the VM is terminated.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
FlexibleGpuId string true The ID of the fGPU you want to modify.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateFlexibleGpuResponse

Example responses

200 Response

{
  "FlexibleGpu": {
    "DeleteOnVmDeletion": true,
    "FlexibleGpuId": "string",
    "Generation": "string",
    "ModelName": "string",
    "State": "string",
    "SubregionName": "string",
    "VmId": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

Image

CreateImage

POST /CreateImage

Creates an OUTSCALE machine image (OMI) from an existing virtual machine (VM) which is either running or stopped.
This action also creates a snapshot of the root volume of the VM, as well as a snapshot of each Block Storage Unit (BSU) volume attached to the VM.

You can also use this method to copy an OMI to your account, from an account in the same Region. To do so, the owner of the source OMI must share it with your account. For more information about how to share an OMI with another account in the same Region, see UpdateImage.
To copy an OMI between accounts in different Regions, the owner of the source OMI must first export it to an OUTSCALE Object Storage (OOS) bucket using the CreateImageExportTask method, and then you need to create a copy of the image in your account.
The copy of the source OMI is independent and belongs to you.

You can also use this method to register an OMI to finalize its creation process.
You can register an OMI from a snapshot of a root device to create an OMI based on this snapshot. You can also register an OMI that has been exported to an S3-compatible bucket to create a copy of it in your account. For more information about OMI export to an OOS bucket, see CreateImageExportTask.
You can register an OMI using a pre-signed URL of the manifest file of the OMI. You do not need any permission for this OMI, or the bucket in which it is contained. The manifest file is obsolete seven days after a completed export as it contains pre-signed URLs to the appropriate snapshots (pre-signed URLs are valid for only seven days).
Once the OMI is registered, you can launch a VM from this OMI. The copy of the source OMI is independent and belongs to you.

Code samples

osc-cli api CreateImage PROFILE \
  --Architecture "string" \
  --BlockDeviceMappings '[ \
      { \
        "Bsu": {"DeleteOnVmDeletion": True, "Iops": 0, "SnapshotId": "string", "VolumeSize": 0, "VolumeType": "string"}, \
        "DeviceName": "string", \
        "VirtualDeviceName": "string" \
      } \
    ]' \
  --Description "string" \
  --DryRun False \
  --FileLocation "string" \
  --ImageName "string" \
  --NoReboot True \
  --RootDeviceName "string" \
  --SourceImageId "string" \
  --SourceRegionName "string" \
  --VmId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateImage \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "Architecture": "string", \
  "BlockDeviceMappings": [ \
    { \
      "Bsu": { \
        "DeleteOnVmDeletion": true, \
        "Iops": 0, \
        "SnapshotId": "string", \
        "VolumeSize": 0, \
        "VolumeType": "string" \
      }, \
      "DeviceName": "string", \
      "VirtualDeviceName": "string" \
    } \
  ], \
  "Description": "string", \
  "DryRun": true, \
  "FileLocation": "string", \
  "ImageName": "string", \
  "NoReboot": true, \
  "RootDeviceName": "string", \
  "SourceImageId": "string", \
  "SourceRegionName": "string", \
  "VmId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "Architecture": "string",
  "BlockDeviceMappings": [ 
    { 
      "Bsu": { 
        "DeleteOnVmDeletion": True, 
        "Iops": 0, 
        "SnapshotId": "string", 
        "VolumeSize": 0, 
        "VolumeType": "string" 
      }, 
      "DeviceName": "string", 
      "VirtualDeviceName": "string" 
    } 
  ],
  "Description": "string",
  "DryRun": False,
  "FileLocation": "string",
  "ImageName": "string",
  "NoReboot": True,
  "RootDeviceName": "string",
  "SourceImageId": "string",
  "SourceRegionName": "string",
  "VmId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateImage', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
Architecture string false The architecture of the OMI (by default, i386).
BlockDeviceMappings [BlockDeviceMappingImage] false One or more block device mappings.
» Bsu BsuToCreate false Information about the BSU volume to create.
»» DeleteOnVmDeletion boolean false By default or if set to true, the volume is deleted when terminating the VM. If false, the volume is not deleted when terminating the VM.
»» Iops integer false The number of I/O operations per second (IOPS). This parameter must be specified only if you create an io1 volume. The maximum number of IOPS allowed for io1 volumes is 13000.
»» SnapshotId string false The ID of the snapshot used to create the volume.
»» VolumeSize integer false The size of the volume, in gibibytes (GiB).
»» VolumeType string false The type of the volume (standard | io1 | gp2). If not specified in the request, a standard volume is created.
» DeviceName string false The name of the device.
» VirtualDeviceName string false The name of the virtual device (ephemeralN).
Description string false A description for the new OMI.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
FileLocation string false The pre-signed URL of the OMI manifest file, or the full path to the OMI stored in a bucket. If you specify this parameter, a copy of the OMI is created in your account.
ImageName string false A unique name for the new OMI.
NoReboot boolean false If false, the VM shuts down before creating the OMI and then reboots. If true, the VM does not.
RootDeviceName string false The name of the root device.
SourceImageId string false The ID of the OMI you want to copy.
SourceRegionName string false The name of the source Region, which must be the same as the Region of your account.
VmId string false The ID of the VM from which you want to create the OMI.

Detailed descriptions

»» VolumeSize: The size of the volume, in gibibytes (GiB).
If you specify a snapshot ID, the volume size must be at least equal to the snapshot size.
If you specify a snapshot ID but no volume size, the volume is created with a size similar to the snapshot one.

»» VolumeType: The type of the volume (standard | io1 | gp2). If not specified in the request, a standard volume is created.
For more information about volume types, see Volume Types and IOPS.

ImageName: A unique name for the new OMI.
Constraints: 3-128 alphanumeric characters, underscores (_), spaces ( ), parentheses (()), slashes (/), periods (.), or dashes (-).

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateImageResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "Image": {
    "AccountAlias": "string",
    "AccountId": "string",
    "Architecture": "string",
    "BlockDeviceMappings": [
      {
        "Bsu": {
          "DeleteOnVmDeletion": true,
          "Iops": 0,
          "SnapshotId": "string",
          "VolumeSize": 0,
          "VolumeType": "string"
        },
        "DeviceName": "string",
        "VirtualDeviceName": "string"
      }
    ],
    "CreationDate": "2019-08-24",
    "Description": "string",
    "FileLocation": "string",
    "ImageId": "string",
    "ImageName": "string",
    "ImageType": "string",
    "PermissionsToLaunch": {
      "AccountIds": [
        "string"
      ],
      "GlobalPermission": true
    },
    "ProductCodes": [
      "string"
    ],
    "RootDeviceName": "string",
    "RootDeviceType": "string",
    "State": "string",
    "StateComment": {
      "StateCode": "string",
      "StateMessage": "string"
    },
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

CreateImageExportTask

POST /CreateImageExportTask

Exports an Outscale machine image (OMI) to an OUTSCALE Object Storage (OOS) bucket.
This action enables you to copy an OMI between accounts in different Regions. To copy an OMI in the same Region, you can also use the CreateImage method.
The copy of the OMI belongs to you and is independent from the source OMI.

[NOTE]
You cannot export a shared or public OMI, as they do not belong to you. To do so, you must first copy it to your account. The copy then belongs to you and you can export it.

Code samples

osc-cli api CreateImageExportTask PROFILE \
  --DryRun False \
  --ImageId "string" \
  --OsuExport '{ \
      "DiskImageFormat": "string", \
      "OsuApiKey": { \
        "ApiKeyId": "string", \
        "SecretKey": "string" \
      }, \
      "OsuBucket": "string", \
      "OsuManifestUrl": "string", \
      "OsuPrefix": "string" \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateImageExportTask \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "ImageId": "string", \
  "OsuExport": { \
    "DiskImageFormat": "string", \
    "OsuApiKey": { \
      "ApiKeyId": "string", \
      "SecretKey": "string" \
    }, \
    "OsuBucket": "string", \
    "OsuManifestUrl": "string", \
    "OsuPrefix": "string" \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "ImageId": "string",
  "OsuExport": { 
    "DiskImageFormat": "string", 
    "OsuApiKey": { 
      "ApiKeyId": "string", 
      "SecretKey": "string" 
    }, 
    "OsuBucket": "string", 
    "OsuManifestUrl": "string", 
    "OsuPrefix": "string" 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateImageExportTask', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
ImageId string true The ID of the OMI to export.
OsuExport OsuExportToCreate true Information about the OOS export task to create.
» DiskImageFormat string true The format of the export disk (qcow2 | raw).
» OsuApiKey OsuApiKey false Information about the OOS API key.
»» ApiKeyId string false The API key of the OOS account that enables you to access the bucket.
»» SecretKey string false The secret key of the OOS account that enables you to access the bucket.
» OsuBucket string true The name of the OOS bucket where you want to export the object.
» OsuManifestUrl string false The URL of the manifest file.
» OsuPrefix string false The prefix for the key of the OOS object.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateImageExportTaskResponse

Example responses

200 Response

{
  "ImageExportTask": {
    "Comment": "string",
    "ImageId": "string",
    "OsuExport": {
      "DiskImageFormat": "string",
      "OsuBucket": "string",
      "OsuManifestUrl": "string",
      "OsuPrefix": "string"
    },
    "Progress": 0,
    "State": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ],
    "TaskId": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteImage

POST /DeleteImage

Deletes an OUTSCALE machine image (OMI) so that you cannot use it anymore to launch virtual machines (VMs). However, you can still use VMs already launched from this OMI.

Code samples

osc-cli api DeleteImage PROFILE \
  --DryRun False \
  --ImageId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteImage \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "ImageId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "ImageId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteImage', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
ImageId string true The ID of the OMI you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteImageResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadImageExportTasks

POST /ReadImageExportTasks

Lists one or more image export tasks.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadImageExportTasks PROFILE \
  --DryRun False \
  --Filters '{ \
      "TaskIds": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadImageExportTasks \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "TaskIds": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "TaskIds": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadImageExportTasks', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersExportTask false One or more filters.
» TaskIds [string] false The IDs of the export tasks.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadImageExportTasksResponse

Example responses

200 Response

{
  "ImageExportTasks": [
    {
      "Comment": "string",
      "ImageId": "string",
      "OsuExport": {
        "DiskImageFormat": "string",
        "OsuBucket": "string",
        "OsuManifestUrl": "string",
        "OsuPrefix": "string"
      },
      "Progress": 0,
      "State": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ],
      "TaskId": "string"
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadImages

POST /ReadImages

Lists one or more OUTSCALE machine images (OMIs) you can use.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadImages PROFILE \
  --DryRun False \
  --Filters '{ \
      "AccountAliases": ["string"], \
      "AccountIds": ["string"], \
      "Architectures": ["string"], \
      "BlockDeviceMappingDeleteOnVmDeletion": True, \
      "BlockDeviceMappingDeviceNames": ["string"], \
      "BlockDeviceMappingSnapshotIds": ["string"], \
      "BlockDeviceMappingVolumeSizes": [0], \
      "BlockDeviceMappingVolumeTypes": ["string"], \
      "Descriptions": ["string"], \
      "FileLocations": ["string"], \
      "Hypervisors": ["string"], \
      "ImageIds": ["string"], \
      "ImageNames": ["string"], \
      "PermissionsToLaunchAccountIds": ["string"], \
      "PermissionsToLaunchGlobalPermission": True, \
      "ProductCodes": ["string"], \
      "RootDeviceNames": ["string"], \
      "RootDeviceTypes": ["string"], \
      "States": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"], \
      "VirtualizationTypes": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadImages \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "AccountAliases": [ \
      "string" \
    ], \
    "AccountIds": [ \
      "string" \
    ], \
    "Architectures": [ \
      "string" \
    ], \
    "BlockDeviceMappingDeleteOnVmDeletion": true, \
    "BlockDeviceMappingDeviceNames": [ \
      "string" \
    ], \
    "BlockDeviceMappingSnapshotIds": [ \
      "string" \
    ], \
    "BlockDeviceMappingVolumeSizes": [ \
      0 \
    ], \
    "BlockDeviceMappingVolumeTypes": [ \
      "string" \
    ], \
    "Descriptions": [ \
      "string" \
    ], \
    "FileLocations": [ \
      "string" \
    ], \
    "Hypervisors": [ \
      "string" \
    ], \
    "ImageIds": [ \
      "string" \
    ], \
    "ImageNames": [ \
      "string" \
    ], \
    "PermissionsToLaunchAccountIds": [ \
      "string" \
    ], \
    "PermissionsToLaunchGlobalPermission": true, \
    "ProductCodes": [ \
      "string" \
    ], \
    "RootDeviceNames": [ \
      "string" \
    ], \
    "RootDeviceTypes": [ \
      "string" \
    ], \
    "States": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ], \
    "VirtualizationTypes": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "AccountAliases": ["string"], 
    "AccountIds": ["string"], 
    "Architectures": ["string"], 
    "BlockDeviceMappingDeleteOnVmDeletion": True, 
    "BlockDeviceMappingDeviceNames": ["string"], 
    "BlockDeviceMappingSnapshotIds": ["string"], 
    "BlockDeviceMappingVolumeSizes": [0], 
    "BlockDeviceMappingVolumeTypes": ["string"], 
    "Descriptions": ["string"], 
    "FileLocations": ["string"], 
    "Hypervisors": ["string"], 
    "ImageIds": ["string"], 
    "ImageNames": ["string"], 
    "PermissionsToLaunchAccountIds": ["string"], 
    "PermissionsToLaunchGlobalPermission": True, 
    "ProductCodes": ["string"], 
    "RootDeviceNames": ["string"], 
    "RootDeviceTypes": ["string"], 
    "States": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"], 
    "VirtualizationTypes": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadImages', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersImage false One or more filters.
» AccountAliases [string] false The account aliases of the owners of the OMIs.
» AccountIds [string] false The account IDs of the owners of the OMIs. By default, all the OMIs for which you have launch permissions are described.
» Architectures [string] false The architectures of the OMIs (i386 | x86_64).
» BlockDeviceMappingDeleteOnVmDeletion boolean false Whether the volumes are deleted or not when terminating the VM.
» BlockDeviceMappingDeviceNames [string] false The device names for the volumes.
» BlockDeviceMappingSnapshotIds [string] false The IDs of the snapshots used to create the volumes.
» BlockDeviceMappingVolumeSizes [integer] false The sizes of the volumes, in gibibytes (GiB).
» BlockDeviceMappingVolumeTypes [string] false The types of volumes (standard | gp2 | io1).
» Descriptions [string] false The descriptions of the OMIs, provided when they were created.
» FileLocations [string] false The locations of the buckets where the OMI files are stored.
» Hypervisors [string] false The hypervisor type of the OMI (always xen).
» ImageIds [string] false The IDs of the OMIs.
» ImageNames [string] false The names of the OMIs, provided when they were created.
» PermissionsToLaunchAccountIds [string] false The account IDs of the users who have launch permissions for the OMIs.
» PermissionsToLaunchGlobalPermission boolean false If true, lists all public OMIs. If false, lists all private OMIs.
» ProductCodes [string] false The product code associated with the OMI (0001 Linux/Unix | 0002 Windows | 0004 Linux/Oracle | 0005 Windows 10).
» RootDeviceNames [string] false The device names of the root devices (for example, /dev/sda1).
» RootDeviceTypes [string] false The types of root device used by the OMIs (always bsu).
» States [string] false The states of the OMIs (pending | available | failed).
» TagKeys [string] false The keys of the tags associated with the OMIs.
» TagValues [string] false The values of the tags associated with the OMIs.
» Tags [string] false The key/value combination of the tags associated with the OMIs, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.
» VirtualizationTypes [string] false The virtualization types (always hvm).

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadImagesResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "Images": [
    {
      "AccountAlias": "string",
      "AccountId": "string",
      "Architecture": "string",
      "BlockDeviceMappings": [
        {
          "Bsu": {
            "DeleteOnVmDeletion": true,
            "Iops": 0,
            "SnapshotId": "string",
            "VolumeSize": 0,
            "VolumeType": "string"
          },
          "DeviceName": "string",
          "VirtualDeviceName": "string"
        }
      ],
      "CreationDate": "2019-08-24",
      "Description": "string",
      "FileLocation": "string",
      "ImageId": "string",
      "ImageName": "string",
      "ImageType": "string",
      "PermissionsToLaunch": {
        "AccountIds": [
          "string"
        ],
        "GlobalPermission": true
      },
      "ProductCodes": [
        "string"
      ],
      "RootDeviceName": "string",
      "RootDeviceType": "string",
      "State": "string",
      "StateComment": {
        "StateCode": "string",
        "StateMessage": "string"
      },
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ]
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

UpdateImage

POST /UpdateImage

Modifies the specified attribute of an OUTSCALE machine image (OMI).
You can specify only one attribute at a time. You can modify the permissions to access the OMI by adding or removing account IDs or groups. You can share an OMI with a user that is in the same Region. The user can create a copy of the OMI you shared, obtaining all the rights for the copy of the OMI. For more information, see CreateImage.

Code samples

osc-cli api UpdateImage PROFILE \
  --DryRun False \
  --ImageId "string" \
  --PermissionsToLaunch '{ \
      "Additions": { \
        "AccountIds": ["string"], \
        "GlobalPermission": True \
      }, \
      "Removals": { \
        "AccountIds": ["string"], \
        "GlobalPermission": True \
      } \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateImage \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "ImageId": "string", \
  "PermissionsToLaunch": { \
    "Additions": { \
      "AccountIds": [ \
        "string" \
      ], \
      "GlobalPermission": true \
    }, \
    "Removals": { \
      "AccountIds": [ \
        "string" \
      ], \
      "GlobalPermission": true \
    } \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "ImageId": "string",
  "PermissionsToLaunch": { 
    "Additions": { 
      "AccountIds": ["string"], 
      "GlobalPermission": True 
    }, 
    "Removals": { 
      "AccountIds": ["string"], 
      "GlobalPermission": True 
    } 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateImage', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
ImageId string true The ID of the OMI you want to modify.
PermissionsToLaunch PermissionsOnResourceCreation true Information about the permissions for the resource.
» Additions PermissionsOnResource false Information about the users who have permissions for the resource.
»» AccountIds [string] false The account ID of one or more users who have permissions for the resource.
»» GlobalPermission boolean false If true, the resource is public. If false, the resource is private.
» Removals PermissionsOnResource false Information about the users who have permissions for the resource.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateImageResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "Image": {
    "AccountAlias": "string",
    "AccountId": "string",
    "Architecture": "string",
    "BlockDeviceMappings": [
      {
        "Bsu": {
          "DeleteOnVmDeletion": true,
          "Iops": 0,
          "SnapshotId": "string",
          "VolumeSize": 0,
          "VolumeType": "string"
        },
        "DeviceName": "string",
        "VirtualDeviceName": "string"
      }
    ],
    "CreationDate": "2019-08-24",
    "Description": "string",
    "FileLocation": "string",
    "ImageId": "string",
    "ImageName": "string",
    "ImageType": "string",
    "PermissionsToLaunch": {
      "AccountIds": [
        "string"
      ],
      "GlobalPermission": true
    },
    "ProductCodes": [
      "string"
    ],
    "RootDeviceName": "string",
    "RootDeviceType": "string",
    "State": "string",
    "StateComment": {
      "StateCode": "string",
      "StateMessage": "string"
    },
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

InternetService

CreateInternetService

POST /CreateInternetService

Creates an Internet service you can use with a Net.
An Internet service enables your virtual machines (VMs) launched in a Net to connect to the Internet. By default, a Net includes an Internet service, and each Subnet is public. Every VM launched within a default Subnet has a private IP and a public IP.

Code samples

osc-cli api CreateInternetService PROFILE \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateInternetService \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateInternetService', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateInternetServiceResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "InternetService": {
    "InternetServiceId": "string",
    "NetId": "string",
    "State": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteInternetService

POST /DeleteInternetService

Deletes an Internet service.
Before deleting an Internet service, you must detach it from any Net it is attached to.

Code samples

osc-cli api DeleteInternetService PROFILE \
  --DryRun False \
  --InternetServiceId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteInternetService \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "InternetServiceId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "InternetServiceId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteInternetService', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
InternetServiceId string true The ID of the Internet service you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteInternetServiceResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

LinkInternetService

POST /LinkInternetService

Attaches an Internet service to a Net.
To enable the connection between the Internet and a Net, you must attach an Internet service to this Net.

Code samples

osc-cli api LinkInternetService PROFILE \
  --DryRun False \
  --InternetServiceId "string" \
  --NetId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/LinkInternetService \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "InternetServiceId": "string", \
  "NetId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "InternetServiceId": "string",
  "NetId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/LinkInternetService', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
InternetServiceId string true The ID of the Internet service you want to attach.
NetId string true The ID of the Net to which you want to attach the Internet service.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). LinkInternetServiceResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadInternetServices

POST /ReadInternetServices

Lists one or more of your Internet services.
An Internet service enables your virtual machines (VMs) launched in a Net to connect to the Internet. By default, a Net includes an Internet service, and each Subnet is public. Every VM launched within a default Subnet has a private IP and a public IP.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadInternetServices PROFILE \
  --DryRun False \
  --Filters '{ \
      "InternetServiceIds": ["string"], \
      "LinkNetIds": ["string"], \
      "LinkStates": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadInternetServices \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "InternetServiceIds": [ \
      "string" \
    ], \
    "LinkNetIds": [ \
      "string" \
    ], \
    "LinkStates": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "InternetServiceIds": ["string"], 
    "LinkNetIds": ["string"], 
    "LinkStates": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadInternetServices', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersInternetService false One or more filters.
» InternetServiceIds [string] false The IDs of the Internet services.
» LinkNetIds [string] false The IDs of the Nets the Internet services are attached to.
» LinkStates [string] false The current states of the attachments between the Internet services and the Nets (only available, if the Internet gateway is attached to a VPC).
» TagKeys [string] false The keys of the tags associated with the Internet services.
» TagValues [string] false The values of the tags associated with the Internet services.
» Tags [string] false The key/value combination of the tags associated with the Internet services, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadInternetServicesResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "InternetServices": [
    {
      "InternetServiceId": "string",
      "NetId": "string",
      "State": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ]
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

UnlinkInternetService

POST /UnlinkInternetService

Detaches an Internet service from a Net.
This action disables and detaches an Internet service from a Net. The Net must not contain any running virtual machine (VM) using a public IP.

Code samples

osc-cli api UnlinkInternetService PROFILE \
  --DryRun False \
  --InternetServiceId "string" \
  --NetId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UnlinkInternetService \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "InternetServiceId": "string", \
  "NetId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "InternetServiceId": "string",
  "NetId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UnlinkInternetService', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
InternetServiceId string true The ID of the Internet service you want to detach.
NetId string true The ID of the Net from which you want to detach the Internet service.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UnlinkInternetServiceResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

Keypair

CreateKeypair

POST /CreateKeypair

Creates a 2048-bit RSA keypair with a specified name.
This action returns the private key that you need to save. The public key is stored by 3DS OUTSCALE.

You can also import a public key in one of the following formats: 1024-bit RSA, 2048-bit RSA, 4096-bit RSA, ECDSA and Ed25519.
This action imports the public key of a keypair created by a third-party tool and uses it to create a new 2048-bit RSA keypair. The private key is never provided to 3DS OUTSCALE.

Code samples

osc-cli api CreateKeypair PROFILE \
  --DryRun False \
  --KeypairName "string" \
  --PublicKey "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateKeypair \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "KeypairName": "string", \
  "PublicKey": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "KeypairName": "string",
  "PublicKey": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateKeypair', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
KeypairName string true A unique name for the keypair, with a maximum length of 255 ASCII printable characters.
PublicKey string false The public key. It must be Base64-encoded.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateKeypairResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
409 Conflict The HTTP 409 response (Conflict). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "Keypair": {
    "KeypairFingerprint": "string",
    "KeypairName": "string",
    "PrivateKey": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteKeypair

POST /DeleteKeypair

Deletes the specified keypair.
This action deletes the public key stored by 3DS OUTSCALE, thus deleting the keypair.

Code samples

osc-cli api DeleteKeypair PROFILE \
  --DryRun False \
  --KeypairName "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteKeypair \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "KeypairName": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "KeypairName": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteKeypair', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
KeypairName string true The name of the keypair you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteKeypairResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadKeypairs

POST /ReadKeypairs

Lists one or more of your keypairs.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadKeypairs PROFILE \
  --DryRun False \
  --Filters '{ \
      "KeypairFingerprints": ["string"], \
      "KeypairNames": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadKeypairs \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "KeypairFingerprints": [ \
      "string" \
    ], \
    "KeypairNames": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "KeypairFingerprints": ["string"], 
    "KeypairNames": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadKeypairs', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersKeypair false One or more filters.
» KeypairFingerprints [string] false The fingerprints of the keypairs.
» KeypairNames [string] false The names of the keypairs.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadKeypairsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "Keypairs": [
    {
      "KeypairFingerprint": "string",
      "KeypairName": "string"
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

Listener

CreateListenerRule

POST /CreateListenerRule

Creates a rule for traffic redirection for the specified listener. Each rule must have either the HostNamePattern or PathPattern parameter specified. Rules are treated in priority order, from the highest value to the lowest value.
Once the rule is created, you need to register backend VMs with it. For more information, see the RegisterVmsInLoadBalancer method.

Code samples

osc-cli api CreateListenerRule PROFILE \
  --DryRun False \
  --Listener '{ \
      "LoadBalancerName": "string", \
      "LoadBalancerPort": 0 \
    }' \
  --ListenerRule '{ \
      "Action": "string", \
      "HostNamePattern": "string", \
      "ListenerRuleName": "string", \
      "PathPattern": "string", \
      "Priority": 0 \
    }' \
  --VmIds '["string"]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateListenerRule \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Listener": { \
    "LoadBalancerName": "string", \
    "LoadBalancerPort": 0 \
  }, \
  "ListenerRule": { \
    "Action": "string", \
    "HostNamePattern": "string", \
    "ListenerRuleName": "string", \
    "PathPattern": "string", \
    "Priority": 0 \
  }, \
  "VmIds": [ \
    "string" \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Listener": { 
    "LoadBalancerName": "string", 
    "LoadBalancerPort": 0 
  },
  "ListenerRule": { 
    "Action": "string", 
    "HostNamePattern": "string", 
    "ListenerRuleName": "string", 
    "PathPattern": "string", 
    "Priority": 0 
  },
  "VmIds": ["string"]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateListenerRule', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Listener LoadBalancerLight true Information about the load balancer.
» LoadBalancerName string true The name of the load balancer to which the listener is attached.
» LoadBalancerPort integer true The port of load balancer on which the load balancer is listening (between 1 and 65535 both included).
ListenerRule ListenerRuleForCreation true Information about the listener rule.
» Action string false The type of action for the rule (always forward).
» HostNamePattern string false A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?].
» ListenerRuleName string true A human-readable name for the listener rule.
» PathPattern string false A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~"'@:+?].
» Priority integer true The priority level of the listener rule, between 1 and 19999 both included. Each rule must have a unique priority level. Otherwise, an error is returned.
VmIds [string] true The IDs of the backend VMs.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateListenerRuleResponse

Example responses

200 Response

{
  "ListenerRule": {
    "Action": "string",
    "HostNamePattern": "string",
    "ListenerId": 0,
    "ListenerRuleId": 0,
    "ListenerRuleName": "string",
    "PathPattern": "string",
    "Priority": 0,
    "VmIds": [
      "string"
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

CreateLoadBalancerListeners

POST /CreateLoadBalancerListeners

Creates one or more listeners for a specified load balancer.

Code samples

osc-cli api CreateLoadBalancerListeners PROFILE \
  --DryRun False \
  --Listeners '[ \
      { \
        "BackendPort": 0, \
        "BackendProtocol": "string", \
        "LoadBalancerPort": 0, \
        "LoadBalancerProtocol": "string", \
        "ServerCertificateId": "string" \
      } \
    ]' \
  --LoadBalancerName "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateLoadBalancerListeners \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Listeners": [ \
    { \
      "BackendPort": 0, \
      "BackendProtocol": "string", \
      "LoadBalancerPort": 0, \
      "LoadBalancerProtocol": "string", \
      "ServerCertificateId": "string" \
    } \
  ], \
  "LoadBalancerName": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Listeners": [ 
    { 
      "BackendPort": 0, 
      "BackendProtocol": "string", 
      "LoadBalancerPort": 0, 
      "LoadBalancerProtocol": "string", 
      "ServerCertificateId": "string" 
    } 
  ],
  "LoadBalancerName": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateLoadBalancerListeners', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Listeners [ListenerForCreation] true One or more listeners for the load balancer.
» BackendPort integer true The port on which the back-end VM is listening (between 1 and 65535, both included).
» BackendProtocol string false The protocol for routing traffic to back-end VMs (HTTP | HTTPS | TCP | SSL).
» LoadBalancerPort integer true The port on which the load balancer is listening (between 1 and 65535, both included).
» LoadBalancerProtocol string true The routing protocol (HTTP | HTTPS | TCP | SSL).
» ServerCertificateId string false The OUTSCALE Resource Name (ORN) of the server certificate. For more information, see Resource Identifiers > OUTSCALE Resource Names (ORNs).
LoadBalancerName string true The name of the load balancer for which you want to create listeners.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateLoadBalancerListenersResponse

Example responses

200 Response

{
  "LoadBalancer": {
    "AccessLog": {
      "IsEnabled": true,
      "OsuBucketName": "string",
      "OsuBucketPrefix": "string",
      "PublicationInterval": 0
    },
    "ApplicationStickyCookiePolicies": [
      {
        "CookieName": "string",
        "PolicyName": "string"
      }
    ],
    "BackendVmIds": [
      "string"
    ],
    "DnsName": "string",
    "HealthCheck": {
      "CheckInterval": 0,
      "HealthyThreshold": 0,
      "Path": "string",
      "Port": 0,
      "Protocol": "string",
      "Timeout": 0,
      "UnhealthyThreshold": 0
    },
    "Listeners": [
      {
        "BackendPort": 0,
        "BackendProtocol": "string",
        "LoadBalancerPort": 0,
        "LoadBalancerProtocol": "string",
        "PolicyNames": [
          "string"
        ],
        "ServerCertificateId": "string"
      }
    ],
    "LoadBalancerName": "string",
    "LoadBalancerStickyCookiePolicies": [
      {
        "CookieExpirationPeriod": 0,
        "PolicyName": "string"
      }
    ],
    "LoadBalancerType": "string",
    "NetId": "string",
    "SecurityGroups": [
      "string"
    ],
    "SourceSecurityGroup": {
      "SecurityGroupAccountId": "string",
      "SecurityGroupName": "string"
    },
    "Subnets": [
      "string"
    ],
    "SubregionNames": [
      "string"
    ],
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteListenerRule

POST /DeleteListenerRule

Deletes a listener rule.
The previously active rule is disabled after deletion.

Code samples

osc-cli api DeleteListenerRule PROFILE \
  --DryRun False \
  --ListenerRuleName "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteListenerRule \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "ListenerRuleName": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "ListenerRuleName": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteListenerRule', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
ListenerRuleName string true The name of the rule you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteListenerRuleResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteLoadBalancerListeners

POST /DeleteLoadBalancerListeners

Deletes listeners of a specified load balancer.

Code samples

osc-cli api DeleteLoadBalancerListeners PROFILE \
  --DryRun False \
  --LoadBalancerName "string" \
  --LoadBalancerPorts '[0]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteLoadBalancerListeners \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "LoadBalancerName": "string", \
  "LoadBalancerPorts": [ \
    0 \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "LoadBalancerName": "string",
  "LoadBalancerPorts": [0]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteLoadBalancerListeners', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LoadBalancerName string true The name of the load balancer for which you want to delete listeners.
LoadBalancerPorts [integer] true One or more port numbers of the listeners you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteLoadBalancerListenersResponse

Example responses

200 Response

{
  "LoadBalancer": {
    "AccessLog": {
      "IsEnabled": true,
      "OsuBucketName": "string",
      "OsuBucketPrefix": "string",
      "PublicationInterval": 0
    },
    "ApplicationStickyCookiePolicies": [
      {
        "CookieName": "string",
        "PolicyName": "string"
      }
    ],
    "BackendVmIds": [
      "string"
    ],
    "DnsName": "string",
    "HealthCheck": {
      "CheckInterval": 0,
      "HealthyThreshold": 0,
      "Path": "string",
      "Port": 0,
      "Protocol": "string",
      "Timeout": 0,
      "UnhealthyThreshold": 0
    },
    "Listeners": [
      {
        "BackendPort": 0,
        "BackendProtocol": "string",
        "LoadBalancerPort": 0,
        "LoadBalancerProtocol": "string",
        "PolicyNames": [
          "string"
        ],
        "ServerCertificateId": "string"
      }
    ],
    "LoadBalancerName": "string",
    "LoadBalancerStickyCookiePolicies": [
      {
        "CookieExpirationPeriod": 0,
        "PolicyName": "string"
      }
    ],
    "LoadBalancerType": "string",
    "NetId": "string",
    "SecurityGroups": [
      "string"
    ],
    "SourceSecurityGroup": {
      "SecurityGroupAccountId": "string",
      "SecurityGroupName": "string"
    },
    "Subnets": [
      "string"
    ],
    "SubregionNames": [
      "string"
    ],
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadListenerRules

POST /ReadListenerRules

Lists one or more listener rules. By default, this action returns the full list of listener rules for the account.

Code samples

osc-cli api ReadListenerRules PROFILE \
  --DryRun False \
  --Filters '{ \
      "ListenerRuleNames": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadListenerRules \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "ListenerRuleNames": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "ListenerRuleNames": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadListenerRules', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersListenerRule false One or more filters.
» ListenerRuleNames [string] false The names of the listener rules.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadListenerRulesResponse

Example responses

200 Response

{
  "ListenerRules": [
    {
      "Action": "string",
      "HostNamePattern": "string",
      "ListenerId": 0,
      "ListenerRuleId": 0,
      "ListenerRuleName": "string",
      "PathPattern": "string",
      "Priority": 0,
      "VmIds": [
        "string"
      ]
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

UpdateListenerRule

POST /UpdateListenerRule

Updates the pattern of the listener rule.
This call updates the pattern matching algorithm for incoming traffic.

Code samples

osc-cli api UpdateListenerRule PROFILE \
  --DryRun False \
  --HostPattern "string" \
  --ListenerRuleName "string" \
  --PathPattern "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateListenerRule \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "HostPattern": "string", \
  "ListenerRuleName": "string", \
  "PathPattern": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "HostPattern": "string",
  "ListenerRuleName": "string",
  "PathPattern": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateListenerRule', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
HostPattern string|null false A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?].
ListenerRuleName string true The name of the listener rule.
PathPattern string|null false A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~"'@:+?].

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateListenerRuleResponse

Example responses

200 Response

{
  "ListenerRule": {
    "Action": "string",
    "HostNamePattern": "string",
    "ListenerId": 0,
    "ListenerRuleId": 0,
    "ListenerRuleName": "string",
    "PathPattern": "string",
    "Priority": 0,
    "VmIds": [
      "string"
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

LoadBalancer

CreateLoadBalancer

POST /CreateLoadBalancer

Creates a load balancer.
The load balancer is created with a unique Domain Name Service (DNS) name. It receives the incoming traffic and routes it to its registered virtual machines (VMs).
By default, this action creates an Internet-facing load balancer, resolving to public IPs. To create an internal load balancer in a Net, resolving to private IPs, use the LoadBalancerType parameter.
You must specify either the Subnets or the SubregionNames parameters.

Code samples

osc-cli api CreateLoadBalancer PROFILE \
  --DryRun False \
  --Listeners '[ \
      { \
        "BackendPort": 0, \
        "BackendProtocol": "string", \
        "LoadBalancerPort": 0, \
        "LoadBalancerProtocol": "string", \
        "ServerCertificateId": "string" \
      } \
    ]' \
  --LoadBalancerName "string" \
  --LoadBalancerType "string" \
  --SecurityGroups '["string"]' \
  --Subnets '["string"]' \
  --SubregionNames '["string"]' \
  --Tags '[ \
      { \
        "Key": "string", \
        "Value": "string" \
      } \
    ]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateLoadBalancer \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Listeners": [ \
    { \
      "BackendPort": 0, \
      "BackendProtocol": "string", \
      "LoadBalancerPort": 0, \
      "LoadBalancerProtocol": "string", \
      "ServerCertificateId": "string" \
    } \
  ], \
  "LoadBalancerName": "string", \
  "LoadBalancerType": "string", \
  "SecurityGroups": [ \
    "string" \
  ], \
  "Subnets": [ \
    "string" \
  ], \
  "SubregionNames": [ \
    "string" \
  ], \
  "Tags": [ \
    { \
      "Key": "string", \
      "Value": "string" \
    } \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Listeners": [ 
    { 
      "BackendPort": 0, 
      "BackendProtocol": "string", 
      "LoadBalancerPort": 0, 
      "LoadBalancerProtocol": "string", 
      "ServerCertificateId": "string" 
    } 
  ],
  "LoadBalancerName": "string",
  "LoadBalancerType": "string",
  "SecurityGroups": ["string"],
  "Subnets": ["string"],
  "SubregionNames": ["string"],
  "Tags": [ 
    { 
      "Key": "string", 
      "Value": "string" 
    } 
  ]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateLoadBalancer', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Listeners [ListenerForCreation] true One or more listeners to create.
» BackendPort integer true The port on which the back-end VM is listening (between 1 and 65535, both included).
» BackendProtocol string false The protocol for routing traffic to back-end VMs (HTTP | HTTPS | TCP | SSL).
» LoadBalancerPort integer true The port on which the load balancer is listening (between 1 and 65535, both included).
» LoadBalancerProtocol string true The routing protocol (HTTP | HTTPS | TCP | SSL).
» ServerCertificateId string false The OUTSCALE Resource Name (ORN) of the server certificate. For more information, see Resource Identifiers > OUTSCALE Resource Names (ORNs).
LoadBalancerName string true The unique name of the load balancer (32 alphanumeric or hyphen characters maximum, but cannot start or end with a hyphen).
LoadBalancerType string false The type of load balancer: internet-facing or internal. Use this parameter only for load balancers in a Net.
SecurityGroups [string] false (Net only) One or more IDs of security groups you want to assign to the load balancer. If not specified, the default security group of the Net is assigned to the load balancer.
Subnets [string] false (Net only) The ID of the Subnet in which you want to create the load balancer. Regardless of this Subnet, the load balancer can distribute traffic to all Subnets. This parameter is required in a Net.
SubregionNames [string] false (public Cloud only) The Subregion in which you want to create the load balancer. Regardless of this Subregion, the load balancer can distribute traffic to all Subregions. This parameter is required in the public Cloud.
Tags [ResourceTag] false One or more tags assigned to the load balancer.
» Key string true The key of the tag, with a minimum of 1 character.
» Value string true The value of the tag, between 0 and 255 characters.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateLoadBalancerResponse

Example responses

200 Response

{
  "LoadBalancer": {
    "AccessLog": {
      "IsEnabled": true,
      "OsuBucketName": "string",
      "OsuBucketPrefix": "string",
      "PublicationInterval": 0
    },
    "ApplicationStickyCookiePolicies": [
      {
        "CookieName": "string",
        "PolicyName": "string"
      }
    ],
    "BackendVmIds": [
      "string"
    ],
    "DnsName": "string",
    "HealthCheck": {
      "CheckInterval": 0,
      "HealthyThreshold": 0,
      "Path": "string",
      "Port": 0,
      "Protocol": "string",
      "Timeout": 0,
      "UnhealthyThreshold": 0
    },
    "Listeners": [
      {
        "BackendPort": 0,
        "BackendProtocol": "string",
        "LoadBalancerPort": 0,
        "LoadBalancerProtocol": "string",
        "PolicyNames": [
          "string"
        ],
        "ServerCertificateId": "string"
      }
    ],
    "LoadBalancerName": "string",
    "LoadBalancerStickyCookiePolicies": [
      {
        "CookieExpirationPeriod": 0,
        "PolicyName": "string"
      }
    ],
    "LoadBalancerType": "string",
    "NetId": "string",
    "SecurityGroups": [
      "string"
    ],
    "SourceSecurityGroup": {
      "SecurityGroupAccountId": "string",
      "SecurityGroupName": "string"
    },
    "Subnets": [
      "string"
    ],
    "SubregionNames": [
      "string"
    ],
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

CreateLoadBalancerTags

POST /CreateLoadBalancerTags

Adds one or more tags to the specified load balancers.
If a tag with the same key already exists for the load balancer, the tag value is replaced.

Code samples

osc-cli api CreateLoadBalancerTags PROFILE \
  --DryRun False \
  --LoadBalancerNames '["string"]' \
  --Tags '[ \
      { \
        "Key": "string", \
        "Value": "string" \
      } \
    ]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateLoadBalancerTags \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "LoadBalancerNames": [ \
    "string" \
  ], \
  "Tags": [ \
    { \
      "Key": "string", \
      "Value": "string" \
    } \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "LoadBalancerNames": ["string"],
  "Tags": [ 
    { 
      "Key": "string", 
      "Value": "string" 
    } 
  ]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateLoadBalancerTags', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LoadBalancerNames [string] true One or more load balancer names.
Tags [ResourceTag] true One or more tags to add to the specified load balancers.
» Key string true The key of the tag, with a minimum of 1 character.
» Value string true The value of the tag, between 0 and 255 characters.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateLoadBalancerTagsResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteLoadBalancer

POST /DeleteLoadBalancer

Deletes a specified load balancer.

Code samples

osc-cli api DeleteLoadBalancer PROFILE \
  --DryRun False \
  --LoadBalancerName "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteLoadBalancer \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "LoadBalancerName": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "LoadBalancerName": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteLoadBalancer', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LoadBalancerName string true The name of the load balancer you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteLoadBalancerResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteLoadBalancerTags

POST /DeleteLoadBalancerTags

Deletes one or more tags from the specified load balancers.

Code samples

osc-cli api DeleteLoadBalancerTags PROFILE \
  --DryRun False \
  --LoadBalancerNames '["string"]' \
  --Tags '[ \
      { \
        "Key": "string" \
      } \
    ]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteLoadBalancerTags \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "LoadBalancerNames": [ \
    "string" \
  ], \
  "Tags": [ \
    { \
      "Key": "string" \
    } \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "LoadBalancerNames": ["string"],
  "Tags": [ 
    { 
      "Key": "string" 
    } 
  ]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteLoadBalancerTags', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LoadBalancerNames [string] true One or more load balancer names.
Tags [ResourceLoadBalancerTag] true One or more tags to delete from the load balancers.
» Key string false The key of the tag, with a minimum of 1 character.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteLoadBalancerTagsResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeregisterVmsInLoadBalancer

POST /DeregisterVmsInLoadBalancer

Deregisters a specified virtual machine (VM) from a load balancer.

Code samples

osc-cli api DeregisterVmsInLoadBalancer PROFILE \
  --BackendVmIds '["string"]' \
  --DryRun False \
  --LoadBalancerName "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeregisterVmsInLoadBalancer \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "BackendVmIds": [ \
    "string" \
  ], \
  "DryRun": true, \
  "LoadBalancerName": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "BackendVmIds": ["string"],
  "DryRun": False,
  "LoadBalancerName": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeregisterVmsInLoadBalancer', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
BackendVmIds [string] true One or more IDs of back-end VMs.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LoadBalancerName string true The name of the load balancer.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeregisterVmsInLoadBalancerResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadLoadBalancerTags

POST /ReadLoadBalancerTags

Lists the tags associated with one or more specified load balancers.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the Throttling error message is returned.

Code samples

osc-cli api ReadLoadBalancerTags PROFILE \
  --DryRun False \
  --LoadBalancerNames '["string"]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadLoadBalancerTags \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "LoadBalancerNames": [ \
    "string" \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "LoadBalancerNames": ["string"]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadLoadBalancerTags', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LoadBalancerNames [string] true One or more load balancer names.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadLoadBalancerTagsResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Tags": [
    {
      "Key": "string",
      "LoadBalancerName": "string",
      "Value": "string"
    }
  ]
}

ReadLoadBalancers

POST /ReadLoadBalancers

Lists one or more load balancers and their attributes.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadLoadBalancers PROFILE \
  --DryRun False \
  --Filters '{ \
      "LoadBalancerNames": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadLoadBalancers \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "LoadBalancerNames": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "LoadBalancerNames": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadLoadBalancers', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersLoadBalancer false One or more filters.
» LoadBalancerNames [string] false The names of the load balancers.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadLoadBalancersResponse

Example responses

200 Response

{
  "LoadBalancers": [
    {
      "AccessLog": {
        "IsEnabled": true,
        "OsuBucketName": "string",
        "OsuBucketPrefix": "string",
        "PublicationInterval": 0
      },
      "ApplicationStickyCookiePolicies": [
        {
          "CookieName": "string",
          "PolicyName": "string"
        }
      ],
      "BackendVmIds": [
        "string"
      ],
      "DnsName": "string",
      "HealthCheck": {
        "CheckInterval": 0,
        "HealthyThreshold": 0,
        "Path": "string",
        "Port": 0,
        "Protocol": "string",
        "Timeout": 0,
        "UnhealthyThreshold": 0
      },
      "Listeners": [
        {
          "BackendPort": 0,
          "BackendProtocol": "string",
          "LoadBalancerPort": 0,
          "LoadBalancerProtocol": "string",
          "PolicyNames": [
            "string"
          ],
          "ServerCertificateId": "string"
        }
      ],
      "LoadBalancerName": "string",
      "LoadBalancerStickyCookiePolicies": [
        {
          "CookieExpirationPeriod": 0,
          "PolicyName": "string"
        }
      ],
      "LoadBalancerType": "string",
      "NetId": "string",
      "SecurityGroups": [
        "string"
      ],
      "SourceSecurityGroup": {
        "SecurityGroupAccountId": "string",
        "SecurityGroupName": "string"
      },
      "Subnets": [
        "string"
      ],
      "SubregionNames": [
        "string"
      ],
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ]
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadVmsHealth

POST /ReadVmsHealth

Lists the state of one or more back-end virtual machines (VMs) registered with a specified load balancer.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the Throttling error message is returned.

Code samples

osc-cli api ReadVmsHealth PROFILE \
  --BackendVmIds '["string"]' \
  --DryRun False \
  --LoadBalancerName "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadVmsHealth \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "BackendVmIds": [ \
    "string" \
  ], \
  "DryRun": true, \
  "LoadBalancerName": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "BackendVmIds": ["string"],
  "DryRun": False,
  "LoadBalancerName": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadVmsHealth', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
BackendVmIds [string] false One or more IDs of back-end VMs.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LoadBalancerName string true The name of the load balancer.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadVmsHealthResponse

Example responses

200 Response

{
  "BackendVmHealth": [
    {
      "Description": "string",
      "State": "string",
      "StateReason": "string",
      "VmId": "string"
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

RegisterVmsInLoadBalancer

POST /RegisterVmsInLoadBalancer

Registers one or more virtual machines (VMs) with a specified load balancer.
The VMs can be in different Subnets and different Subregions than the load balancer, as long as the VMs and load balancers are all in the public Cloud or all in the same Net. It may take a little time for a VM to be registered with the load balancer. Once the VM is registered with a load balancer, it receives traffic and requests from this load balancer and is called a back-end VM.

Code samples

osc-cli api RegisterVmsInLoadBalancer PROFILE \
  --BackendVmIds '["string"]' \
  --DryRun False \
  --LoadBalancerName "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/RegisterVmsInLoadBalancer \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "BackendVmIds": [ \
    "string" \
  ], \
  "DryRun": true, \
  "LoadBalancerName": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "BackendVmIds": ["string"],
  "DryRun": False,
  "LoadBalancerName": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/RegisterVmsInLoadBalancer', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
BackendVmIds [string] true One or more IDs of back-end VMs.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LoadBalancerName string true The name of the load balancer.

Detailed descriptions

BackendVmIds: One or more IDs of back-end VMs.
Specifying the same ID several times has no effect as each back-end VM has equal weight.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). RegisterVmsInLoadBalancerResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

UpdateLoadBalancer

POST /UpdateLoadBalancer

Modifies the specified attribute of a load balancer. You can specify only one attribute at a time.

You can set a new SSL certificate to an SSL or HTTPS listener of a load balancer.
This certificate replaces any certificate used on the same load balancer and port.

You can also replace the currently enabled policy for the load balancer with another one.
If the PolicyNames parameter is empty, the currently enabled policy is disabled.

Code samples

osc-cli api UpdateLoadBalancer PROFILE \
  --AccessLog '{ \
      "IsEnabled": True, \
      "OsuBucketName": "string", \
      "OsuBucketPrefix": "string", \
      "PublicationInterval": 0 \
    }' \
  --DryRun False \
  --HealthCheck '{ \
      "CheckInterval": 0, \
      "HealthyThreshold": 0, \
      "Path": "string", \
      "Port": 0, \
      "Protocol": "string", \
      "Timeout": 0, \
      "UnhealthyThreshold": 0 \
    }' \
  --LoadBalancerName "string" \
  --LoadBalancerPort 0 \
  --PolicyNames '["string"]' \
  --SecurityGroups '["string"]' \
  --ServerCertificateId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateLoadBalancer \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "AccessLog": { \
    "IsEnabled": true, \
    "OsuBucketName": "string", \
    "OsuBucketPrefix": "string", \
    "PublicationInterval": 0 \
  }, \
  "DryRun": true, \
  "HealthCheck": { \
    "CheckInterval": 0, \
    "HealthyThreshold": 0, \
    "Path": "string", \
    "Port": 0, \
    "Protocol": "string", \
    "Timeout": 0, \
    "UnhealthyThreshold": 0 \
  }, \
  "LoadBalancerName": "string", \
  "LoadBalancerPort": 0, \
  "PolicyNames": [ \
    "string" \
  ], \
  "SecurityGroups": [ \
    "string" \
  ], \
  "ServerCertificateId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "AccessLog": { 
    "IsEnabled": True, 
    "OsuBucketName": "string", 
    "OsuBucketPrefix": "string", 
    "PublicationInterval": 0 
  },
  "DryRun": False,
  "HealthCheck": { 
    "CheckInterval": 0, 
    "HealthyThreshold": 0, 
    "Path": "string", 
    "Port": 0, 
    "Protocol": "string", 
    "Timeout": 0, 
    "UnhealthyThreshold": 0 
  },
  "LoadBalancerName": "string",
  "LoadBalancerPort": 0,
  "PolicyNames": ["string"],
  "SecurityGroups": ["string"],
  "ServerCertificateId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateLoadBalancer', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
AccessLog AccessLog false Information about access logs.
» IsEnabled boolean false If true, access logs are enabled for your load balancer. If false, they are not. If you set this to true in your request, the OsuBucketName parameter is required.
» OsuBucketName string false The name of the OOS bucket for the access logs.
» OsuBucketPrefix string false The path to the folder of the access logs in your OOS bucket (by default, the root level of your bucket).
» PublicationInterval integer false The time interval for the publication of access logs in the OOS bucket, in minutes. This value can be either 5 or 60 (by default, 60).
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
HealthCheck HealthCheck false Information about the health check configuration.
» CheckInterval integer true The number of seconds between two pings (between 5 and 600 both included).
» HealthyThreshold integer true The number of consecutive successful pings before considering the VM as healthy (between 2 and 10 both included).
» Path string false If you use the HTTP or HTTPS protocols, the ping path.
» Port integer true The port number (between 1 and 65535, both included).
» Protocol string true The protocol for the URL of the VM (HTTP | HTTPS | TCP | SSL).
» Timeout integer true The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between 2 and 60 both included).
» UnhealthyThreshold integer true The number of consecutive failed pings before considering the VM as unhealthy (between 2 and 10 both included).
LoadBalancerName string true The name of the load balancer.
LoadBalancerPort integer false The port on which the load balancer is listening (between 1 and 65535, both included). This parameter is required if you want to update the server certificate.
PolicyNames [string] false The name of the policy you want to enable for the listener.
SecurityGroups [string] false (Net only) One or more IDs of security groups you want to assign to the load balancer. You need to specify the already assigned security groups that you want to keep along with the new ones you are assigning. If the list is empty, the default security group of the Net is assigned to the load balancer.
ServerCertificateId string false The Outscale Resource Name (ORN) of the server certificate. For more information, see Resource Identifiers > Outscale Resource Names (ORNs). If this parameter is specified, you must also specify the LoadBalancerPort parameter.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateLoadBalancerResponse

Example responses

200 Response

{
  "LoadBalancer": {
    "AccessLog": {
      "IsEnabled": true,
      "OsuBucketName": "string",
      "OsuBucketPrefix": "string",
      "PublicationInterval": 0
    },
    "ApplicationStickyCookiePolicies": [
      {
        "CookieName": "string",
        "PolicyName": "string"
      }
    ],
    "BackendVmIds": [
      "string"
    ],
    "DnsName": "string",
    "HealthCheck": {
      "CheckInterval": 0,
      "HealthyThreshold": 0,
      "Path": "string",
      "Port": 0,
      "Protocol": "string",
      "Timeout": 0,
      "UnhealthyThreshold": 0
    },
    "Listeners": [
      {
        "BackendPort": 0,
        "BackendProtocol": "string",
        "LoadBalancerPort": 0,
        "LoadBalancerProtocol": "string",
        "PolicyNames": [
          "string"
        ],
        "ServerCertificateId": "string"
      }
    ],
    "LoadBalancerName": "string",
    "LoadBalancerStickyCookiePolicies": [
      {
        "CookieExpirationPeriod": 0,
        "PolicyName": "string"
      }
    ],
    "LoadBalancerType": "string",
    "NetId": "string",
    "SecurityGroups": [
      "string"
    ],
    "SourceSecurityGroup": {
      "SecurityGroupAccountId": "string",
      "SecurityGroupName": "string"
    },
    "Subnets": [
      "string"
    ],
    "SubregionNames": [
      "string"
    ],
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

LoadBalancerPolicy

CreateLoadBalancerPolicy

POST /CreateLoadBalancerPolicy

Creates a stickiness policy with sticky session lifetimes defined by the browser lifetime.
The created policy can be used with HTTP or HTTPS listeners only.
If this policy is implemented by a load balancer, this load balancer uses this cookie in all incoming requests to direct them to the specified back-end server virtual machine (VM). If this cookie is not present, the load balancer sends the request to any other server according to its load-balancing algorithm.

You can also create a stickiness policy with sticky session lifetimes following the lifetime of an application-generated cookie.
Unlike the other type of stickiness policy, the lifetime of the special Load Balancer Unit (LBU) cookie follows the lifetime of the application-generated cookie specified in the policy configuration. The load balancer inserts a new stickiness cookie only when the application response includes a new application cookie.
The session stops being sticky if the application cookie is removed or expires, until a new application cookie is issued.

Code samples

osc-cli api CreateLoadBalancerPolicy PROFILE \
  --CookieExpirationPeriod 0 \
  --CookieName "string" \
  --DryRun False \
  --LoadBalancerName "string" \
  --PolicyName "string" \
  --PolicyType "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateLoadBalancerPolicy \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "CookieExpirationPeriod": 0, \
  "CookieName": "string", \
  "DryRun": true, \
  "LoadBalancerName": "string", \
  "PolicyName": "string", \
  "PolicyType": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "CookieExpirationPeriod": 0,
  "CookieName": "string",
  "DryRun": False,
  "LoadBalancerName": "string",
  "PolicyName": "string",
  "PolicyType": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateLoadBalancerPolicy', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
CookieExpirationPeriod integer false The lifetime of the cookie, in seconds. If not specified, the default value of this parameter is 1, which means that the sticky session lasts for the duration of the browser session.
CookieName string false The name of the application cookie used for stickiness. This parameter is required if you create a stickiness policy based on an application-generated cookie.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LoadBalancerName string true The name of the load balancer for which you want to create a policy.
PolicyName string true The name of the policy. This name must be unique and consist of alphanumeric characters and dashes (-).
PolicyType string true The type of stickiness policy you want to create: app or load_balancer.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateLoadBalancerPolicyResponse

Example responses

200 Response

{
  "LoadBalancer": {
    "AccessLog": {
      "IsEnabled": true,
      "OsuBucketName": "string",
      "OsuBucketPrefix": "string",
      "PublicationInterval": 0
    },
    "ApplicationStickyCookiePolicies": [
      {
        "CookieName": "string",
        "PolicyName": "string"
      }
    ],
    "BackendVmIds": [
      "string"
    ],
    "DnsName": "string",
    "HealthCheck": {
      "CheckInterval": 0,
      "HealthyThreshold": 0,
      "Path": "string",
      "Port": 0,
      "Protocol": "string",
      "Timeout": 0,
      "UnhealthyThreshold": 0
    },
    "Listeners": [
      {
        "BackendPort": 0,
        "BackendProtocol": "string",
        "LoadBalancerPort": 0,
        "LoadBalancerProtocol": "string",
        "PolicyNames": [
          "string"
        ],
        "ServerCertificateId": "string"
      }
    ],
    "LoadBalancerName": "string",
    "LoadBalancerStickyCookiePolicies": [
      {
        "CookieExpirationPeriod": 0,
        "PolicyName": "string"
      }
    ],
    "LoadBalancerType": "string",
    "NetId": "string",
    "SecurityGroups": [
      "string"
    ],
    "SourceSecurityGroup": {
      "SecurityGroupAccountId": "string",
      "SecurityGroupName": "string"
    },
    "Subnets": [
      "string"
    ],
    "SubregionNames": [
      "string"
    ],
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteLoadBalancerPolicy

POST /DeleteLoadBalancerPolicy

Deletes a specified policy from a load balancer.
In order to be deleted, the policy must not be enabled for any listener.

Code samples

osc-cli api DeleteLoadBalancerPolicy PROFILE \
  --DryRun False \
  --LoadBalancerName "string" \
  --PolicyName "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteLoadBalancerPolicy \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "LoadBalancerName": "string", \
  "PolicyName": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "LoadBalancerName": "string",
  "PolicyName": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteLoadBalancerPolicy', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LoadBalancerName string true The name of the load balancer for which you want to delete a policy.
PolicyName string true The name of the policy you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteLoadBalancerPolicyResponse

Example responses

200 Response

{
  "LoadBalancer": {
    "AccessLog": {
      "IsEnabled": true,
      "OsuBucketName": "string",
      "OsuBucketPrefix": "string",
      "PublicationInterval": 0
    },
    "ApplicationStickyCookiePolicies": [
      {
        "CookieName": "string",
        "PolicyName": "string"
      }
    ],
    "BackendVmIds": [
      "string"
    ],
    "DnsName": "string",
    "HealthCheck": {
      "CheckInterval": 0,
      "HealthyThreshold": 0,
      "Path": "string",
      "Port": 0,
      "Protocol": "string",
      "Timeout": 0,
      "UnhealthyThreshold": 0
    },
    "Listeners": [
      {
        "BackendPort": 0,
        "BackendProtocol": "string",
        "LoadBalancerPort": 0,
        "LoadBalancerProtocol": "string",
        "PolicyNames": [
          "string"
        ],
        "ServerCertificateId": "string"
      }
    ],
    "LoadBalancerName": "string",
    "LoadBalancerStickyCookiePolicies": [
      {
        "CookieExpirationPeriod": 0,
        "PolicyName": "string"
      }
    ],
    "LoadBalancerType": "string",
    "NetId": "string",
    "SecurityGroups": [
      "string"
    ],
    "SourceSecurityGroup": {
      "SecurityGroupAccountId": "string",
      "SecurityGroupName": "string"
    },
    "Subnets": [
      "string"
    ],
    "SubregionNames": [
      "string"
    ],
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

Location

ReadLocations

POST /ReadLocations

Lists the locations, corresponding to datacenters, where you can set up a DirectLink.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the Throttling error message is returned.

Code samples

osc-cli api ReadLocations PROFILE \
  --DryRun False 

curl -X POST https://api.{region}.outscale.com/api/v1/ReadLocations \
  -H 'Content-Type: application/json' \
  -d '{ \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}
params = { 
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadLocations', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadLocationsResponse

Example responses

200 Response

{
  "Locations": [
    {
      "Code": "string",
      "Name": "string"
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

NatService

CreateNatService

POST /CreateNatService

Creates a network address translation (NAT) service in the specified public Subnet of a Net.
A NAT service enables virtual machines (VMs) placed in the private Subnet of this Net to connect to the Internet, without being accessible from the Internet.
When creating a NAT service, you specify the allocation ID of the public IP you want to use as public IP for the NAT service. Once the NAT service is created, you need to create a route in the route table of the private Subnet, with 0.0.0.0/0 as destination and the ID of the NAT service as target. For more information, see LinkPublicIP and CreateRoute.
This action also enables you to create multiple NAT services in the same Net (one per public Subnet).

[NOTE]
You cannot modify the public IP associated with a NAT service after its creation. To do so, you need to delete the NAT service and create a new one with another public IP.

Code samples

osc-cli api CreateNatService PROFILE \
  --DryRun False \
  --PublicIpId "string" \
  --SubnetId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateNatService \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "PublicIpId": "string", \
  "SubnetId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "PublicIpId": "string",
  "SubnetId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateNatService', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
PublicIpId string true The allocation ID of the public IP to associate with the NAT service.
SubnetId string true The ID of the Subnet in which you want to create the NAT service.

Detailed descriptions

PublicIpId: The allocation ID of the public IP to associate with the NAT service.
If the public IP is already associated with another resource, you must first disassociate it.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateNatServiceResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "NatService": {
    "NatServiceId": "string",
    "NetId": "string",
    "PublicIps": [
      {
        "PublicIp": "string",
        "PublicIpId": "string"
      }
    ],
    "State": "string",
    "SubnetId": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteNatService

POST /DeleteNatService

Deletes a specified network address translation (NAT) service.
This action disassociates the public IP from the NAT service, but does not release this public IP from your account. However, it does not delete any NAT service routes in your route tables.

Code samples

osc-cli api DeleteNatService PROFILE \
  --DryRun False \
  --NatServiceId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteNatService \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "NatServiceId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "NatServiceId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteNatService', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NatServiceId string true The ID of the NAT service you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteNatServiceResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadNatServices

POST /ReadNatServices

Lists one or more network address translation (NAT) services.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadNatServices PROFILE \
  --DryRun False \
  --Filters '{ \
      "NatServiceIds": ["string"], \
      "NetIds": ["string"], \
      "States": ["string"], \
      "SubnetIds": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadNatServices \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "NatServiceIds": [ \
      "string" \
    ], \
    "NetIds": [ \
      "string" \
    ], \
    "States": [ \
      "string" \
    ], \
    "SubnetIds": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "NatServiceIds": ["string"], 
    "NetIds": ["string"], 
    "States": ["string"], 
    "SubnetIds": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadNatServices', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersNatService false One or more filters.
» NatServiceIds [string] false The IDs of the NAT services.
» NetIds [string] false The IDs of the Nets in which the NAT services are.
» States [string] false The states of the NAT services (pending | available | deleting | deleted).
» SubnetIds [string] false The IDs of the Subnets in which the NAT services are.
» TagKeys [string] false The keys of the tags associated with the NAT services.
» TagValues [string] false The values of the tags associated with the NAT services.
» Tags [string] false The key/value combination of the tags associated with the NAT services, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadNatServicesResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "NatServices": [
    {
      "NatServiceId": "string",
      "NetId": "string",
      "PublicIps": [
        {
          "PublicIp": "string",
          "PublicIpId": "string"
        }
      ],
      "State": "string",
      "SubnetId": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ]
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

Net

CreateNet

POST /CreateNet

Creates a Net with a specified IP range.
The IP range (network range) of your Net must be between a /28 netmask (16 IPs) and a /16 netmask (65536 IPs).

Code samples

osc-cli api CreateNet PROFILE \
  --DryRun False \
  --IpRange "string" \
  --Tenancy "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateNet \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "IpRange": "string", \
  "Tenancy": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "IpRange": "string",
  "Tenancy": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateNet', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
IpRange string true The IP range for the Net, in CIDR notation (for example, 10.0.0.0/16).
Tenancy string false The tenancy options for the VMs (default if a VM created in a Net can be launched with any tenancy, dedicated if it can be launched with dedicated tenancy VMs running on single-tenant hardware).

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateNetResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
409 Conflict The HTTP 409 response (Conflict). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "Net": {
    "DhcpOptionsSetId": "string",
    "IpRange": "string",
    "NetId": "string",
    "State": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ],
    "Tenancy": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteNet

POST /DeleteNet

Deletes a specified Net.
Before deleting the Net, you need to delete or detach all the resources associated with the Net:

Code samples

osc-cli api DeleteNet PROFILE \
  --DryRun False \
  --NetId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteNet \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "NetId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "NetId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteNet', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NetId string true The ID of the Net you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteNetResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadNets

POST /ReadNets

Lists one or more Nets.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadNets PROFILE \
  --DryRun False \
  --Filters '{ \
      "DhcpOptionsSetIds": ["string"], \
      "IpRanges": ["string"], \
      "IsDefault": True, \
      "NetIds": ["string"], \
      "States": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadNets \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "DhcpOptionsSetIds": [ \
      "string" \
    ], \
    "IpRanges": [ \
      "string" \
    ], \
    "IsDefault": true, \
    "NetIds": [ \
      "string" \
    ], \
    "States": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "DhcpOptionsSetIds": ["string"], 
    "IpRanges": ["string"], 
    "IsDefault": True, 
    "NetIds": ["string"], 
    "States": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadNets', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersNet false One or more filters.
» DhcpOptionsSetIds [string] false The IDs of the DHCP options sets.
» IpRanges [string] false The IP ranges for the Nets, in CIDR notation (for example, 10.0.0.0/16).
» IsDefault boolean false If true, the Net used is the default one.
» NetIds [string] false The IDs of the Nets.
» States [string] false The states of the Nets (pending | available).
» TagKeys [string] false The keys of the tags associated with the Nets.
» TagValues [string] false The values of the tags associated with the Nets.
» Tags [string] false The key/value combination of the tags associated with the Nets, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadNetsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "Nets": [
    {
      "DhcpOptionsSetId": "string",
      "IpRange": "string",
      "NetId": "string",
      "State": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ],
      "Tenancy": "string"
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

UpdateNet

POST /UpdateNet

Associates a DHCP options set with a specified Net.

Code samples

osc-cli api UpdateNet PROFILE \
  --DhcpOptionsSetId "string" \
  --DryRun False \
  --NetId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateNet \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DhcpOptionsSetId": "string", \
  "DryRun": true, \
  "NetId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DhcpOptionsSetId": "string",
  "DryRun": False,
  "NetId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateNet', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DhcpOptionsSetId string true The ID of the DHCP options set (or default if you want to associate the default one).
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NetId string true The ID of the Net.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateNetResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "Net": {
    "DhcpOptionsSetId": "string",
    "IpRange": "string",
    "NetId": "string",
    "State": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ],
    "Tenancy": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

NetAccessPoint

CreateNetAccessPoint

POST /CreateNetAccessPoint

Creates a Net access point to access an OUTSCALE service from this Net without using the Internet and public IPs.
You specify the service using its name. For more information about the available services, see ReadNetAccessPointServices.
To control the routing of traffic between the Net and the specified service, you can specify one or more route tables. Virtual machines placed in Subnets associated with the specified route table thus use the Net access point to access the service. When you specify a route table, a route is automatically added to it with the destination set to the prefix list ID of the service, and the target set to the ID of the access point.

Code samples

osc-cli api CreateNetAccessPoint PROFILE \
  --DryRun False \
  --NetId "string" \
  --RouteTableIds '["string"]' \
  --ServiceName "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateNetAccessPoint \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "NetId": "string", \
  "RouteTableIds": [ \
    "string" \
  ], \
  "ServiceName": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "NetId": "string",
  "RouteTableIds": ["string"],
  "ServiceName": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateNetAccessPoint', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NetId string true The ID of the Net.
RouteTableIds [string] false One or more IDs of route tables to use for the connection.
ServiceName string true The name of the service (in the format com.outscale.region.service).

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateNetAccessPointResponse

Example responses

200 Response

{
  "NetAccessPoint": {
    "NetAccessPointId": "string",
    "NetId": "string",
    "RouteTableIds": [
      "string"
    ],
    "ServiceName": "string",
    "State": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteNetAccessPoint

POST /DeleteNetAccessPoint

Deletes one or more Net access point.
This action also deletes the corresponding routes added to the route tables you specified for the Net access point.

Code samples

osc-cli api DeleteNetAccessPoint PROFILE \
  --DryRun False \
  --NetAccessPointId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteNetAccessPoint \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "NetAccessPointId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "NetAccessPointId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteNetAccessPoint', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NetAccessPointId string true The ID of the Net access point.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteNetAccessPointResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadNetAccessPointServices

POST /ReadNetAccessPointServices

Lists OUTSCALE services available to create Net access points.
For more information, see CreateNetAccessPoint.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadNetAccessPointServices PROFILE \
  --DryRun False \
  --Filters '{ \
      "ServiceIds": ["string"], \
      "ServiceNames": ["string"] \
    }' 

curl -X POST https://api.{region}.outscale.com/api/v1/ReadNetAccessPointServices \
  -H 'Content-Type: application/json' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "ServiceIds": [ \
      "string" \
    ], \
    "ServiceNames": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "ServiceIds": ["string"], 
    "ServiceNames": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadNetAccessPointServices', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersService false One or more filters.
» ServiceIds [string] false The IDs of the services.
» ServiceNames [string] false The names of the services.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadNetAccessPointServicesResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Services": [
    {
      "IpRanges": [
        "string"
      ],
      "ServiceId": "string",
      "ServiceName": "string"
    }
  ]
}

ReadNetAccessPoints

POST /ReadNetAccessPoints

Lists one or more Net access points.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadNetAccessPoints PROFILE \
  --DryRun False \
  --Filters '{ \
      "NetAccessPointIds": ["string"], \
      "NetIds": ["string"], \
      "ServiceNames": ["string"], \
      "States": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadNetAccessPoints \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "NetAccessPointIds": [ \
      "string" \
    ], \
    "NetIds": [ \
      "string" \
    ], \
    "ServiceNames": [ \
      "string" \
    ], \
    "States": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "NetAccessPointIds": ["string"], 
    "NetIds": ["string"], 
    "ServiceNames": ["string"], 
    "States": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadNetAccessPoints', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersNetAccessPoint false One or more filters.
» NetAccessPointIds [string] false The IDs of the Net access points.
» NetIds [string] false The IDs of the Nets.
» ServiceNames [string] false The names of the services. For more information, see ReadNetAccessPointServices.
» States [string] false The states of the Net access points (pending | available | deleting | deleted).
» TagKeys [string] false The keys of the tags associated with the Net access points.
» TagValues [string] false The values of the tags associated with the Net access points.
» Tags [string] false The key/value combination of the tags associated with the Net access points, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadNetAccessPointsResponse

Example responses

200 Response

{
  "NetAccessPoints": [
    {
      "NetAccessPointId": "string",
      "NetId": "string",
      "RouteTableIds": [
        "string"
      ],
      "ServiceName": "string",
      "State": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ]
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

UpdateNetAccessPoint

POST /UpdateNetAccessPoint

Modifies the attributes of a Net access point.
This action enables you to add or remove route tables associated with the specified Net access point.

Code samples

osc-cli api UpdateNetAccessPoint PROFILE \
  --AddRouteTableIds '["string"]' \
  --DryRun False \
  --NetAccessPointId "string" \
  --RemoveRouteTableIds '["string"]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateNetAccessPoint \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "AddRouteTableIds": [ \
    "string" \
  ], \
  "DryRun": true, \
  "NetAccessPointId": "string", \
  "RemoveRouteTableIds": [ \
    "string" \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "AddRouteTableIds": ["string"],
  "DryRun": False,
  "NetAccessPointId": "string",
  "RemoveRouteTableIds": ["string"]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateNetAccessPoint', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
AddRouteTableIds [string] false One or more IDs of route tables to associate with the specified Net access point.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NetAccessPointId string true The ID of the Net access point.
RemoveRouteTableIds [string] false One or more IDs of route tables to disassociate from the specified Net access point.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateNetAccessPointResponse

Example responses

200 Response

{
  "NetAccessPoint": {
    "NetAccessPointId": "string",
    "NetId": "string",
    "RouteTableIds": [
      "string"
    ],
    "ServiceName": "string",
    "State": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

NetPeering

AcceptNetPeering

POST /AcceptNetPeering

Accepts a Net peering connection request.
To accept this request, you must be the owner of the peer Net. If you do not accept the request within 7 days, the state of the Net peering connection becomes expired.

[NOTE]
A peering connection between two Nets works both ways. Therefore, when an A-to-B peering connection is accepted, any pending B-to-A peering connection is automatically rejected as redundant.

Code samples

osc-cli api AcceptNetPeering PROFILE \
  --DryRun False \
  --NetPeeringId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/AcceptNetPeering \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "NetPeeringId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "NetPeeringId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/AcceptNetPeering', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NetPeeringId string true The ID of the Net peering connection you want to accept.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). AcceptNetPeeringResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
409 Conflict The HTTP 409 response (Conflict). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "NetPeering": {
    "AccepterNet": {
      "AccountId": "string",
      "IpRange": "string",
      "NetId": "string"
    },
    "NetPeeringId": "string",
    "SourceNet": {
      "AccountId": "string",
      "IpRange": "string",
      "NetId": "string"
    },
    "State": {
      "Message": "string",
      "Name": "string"
    },
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

CreateNetPeering

POST /CreateNetPeering

Requests a Net peering connection between a Net you own and a peer Net that belongs to you or another account.
This action creates a Net peering connection that remains in the pending-acceptance state until it is accepted by the owner of the peer Net. If the owner of the peer Net does not accept the request within 7 days, the state of the Net peering connection becomes expired. For more information, see AcceptNetPeering.

[NOTE]

Code samples

osc-cli api CreateNetPeering PROFILE \
  --AccepterNetId "string" \
  --DryRun False \
  --SourceNetId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateNetPeering \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "AccepterNetId": "string", \
  "DryRun": true, \
  "SourceNetId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "AccepterNetId": "string",
  "DryRun": False,
  "SourceNetId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateNetPeering', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
AccepterNetId string true The ID of the Net you want to connect with.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
SourceNetId string true The ID of the Net you send the peering request from.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateNetPeeringResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "NetPeering": {
    "AccepterNet": {
      "AccountId": "string",
      "IpRange": "string",
      "NetId": "string"
    },
    "NetPeeringId": "string",
    "SourceNet": {
      "AccountId": "string",
      "IpRange": "string",
      "NetId": "string"
    },
    "State": {
      "Message": "string",
      "Name": "string"
    },
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteNetPeering

POST /DeleteNetPeering

Deletes a Net peering connection.
If the Net peering connection is in the active state, it can be deleted either by the owner of the requester Net or the owner of the peer Net.
If it is in the pending-acceptance state, it can be deleted only by the owner of the requester Net.
If it is in the rejected, failed, or expired states, it cannot be deleted.

Code samples

osc-cli api DeleteNetPeering PROFILE \
  --DryRun False \
  --NetPeeringId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteNetPeering \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "NetPeeringId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "NetPeeringId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteNetPeering', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NetPeeringId string true The ID of the Net peering connection you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteNetPeeringResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
409 Conflict The HTTP 409 response (Conflict). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadNetPeerings

POST /ReadNetPeerings

Lists one or more peering connections between two Nets.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadNetPeerings PROFILE \
  --DryRun False \
  --Filters '{ \
      "AccepterNetAccountIds": ["string"], \
      "AccepterNetIpRanges": ["string"], \
      "AccepterNetNetIds": ["string"], \
      "NetPeeringIds": ["string"], \
      "SourceNetAccountIds": ["string"], \
      "SourceNetIpRanges": ["string"], \
      "SourceNetNetIds": ["string"], \
      "StateMessages": ["string"], \
      "StateNames": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadNetPeerings \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "AccepterNetAccountIds": [ \
      "string" \
    ], \
    "AccepterNetIpRanges": [ \
      "string" \
    ], \
    "AccepterNetNetIds": [ \
      "string" \
    ], \
    "NetPeeringIds": [ \
      "string" \
    ], \
    "SourceNetAccountIds": [ \
      "string" \
    ], \
    "SourceNetIpRanges": [ \
      "string" \
    ], \
    "SourceNetNetIds": [ \
      "string" \
    ], \
    "StateMessages": [ \
      "string" \
    ], \
    "StateNames": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "AccepterNetAccountIds": ["string"], 
    "AccepterNetIpRanges": ["string"], 
    "AccepterNetNetIds": ["string"], 
    "NetPeeringIds": ["string"], 
    "SourceNetAccountIds": ["string"], 
    "SourceNetIpRanges": ["string"], 
    "SourceNetNetIds": ["string"], 
    "StateMessages": ["string"], 
    "StateNames": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadNetPeerings', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersNetPeering false One or more filters.
» AccepterNetAccountIds [string] false The account IDs of the owners of the peer Nets.
» AccepterNetIpRanges [string] false The IP ranges of the peer Nets, in CIDR notation (for example, 10.0.0.0/24).
» AccepterNetNetIds [string] false The IDs of the peer Nets.
» NetPeeringIds [string] false The IDs of the Net peering connections.
» SourceNetAccountIds [string] false The account IDs of the owners of the peer Nets.
» SourceNetIpRanges [string] false The IP ranges of the peer Nets.
» SourceNetNetIds [string] false The IDs of the peer Nets.
» StateMessages [string] false Additional information about the states of the Net peering connections.
» StateNames [string] false The states of the Net peering connections (pending-acceptance | active | rejected | failed | expired | deleted).
» TagKeys [string] false The keys of the tags associated with the Net peering connections.
» TagValues [string] false The values of the tags associated with the Net peering connections.
» Tags [string] false The key/value combination of the tags associated with the Net peering connections, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadNetPeeringsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "NetPeerings": [
    {
      "AccepterNet": {
        "AccountId": "string",
        "IpRange": "string",
        "NetId": "string"
      },
      "NetPeeringId": "string",
      "SourceNet": {
        "AccountId": "string",
        "IpRange": "string",
        "NetId": "string"
      },
      "State": {
        "Message": "string",
        "Name": "string"
      },
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ]
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

RejectNetPeering

POST /RejectNetPeering

Rejects a Net peering connection request.
The Net peering connection must be in the pending-acceptance state to be rejected. The rejected Net peering connection is then in the rejected state.

Code samples

osc-cli api RejectNetPeering PROFILE \
  --DryRun False \
  --NetPeeringId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/RejectNetPeering \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "NetPeeringId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "NetPeeringId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/RejectNetPeering', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NetPeeringId string true The ID of the Net peering connection you want to reject.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). RejectNetPeeringResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
409 Conflict The HTTP 409 response (Conflict). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

Nic

CreateNic

POST /CreateNic

Creates a network interface card (NIC) in the specified Subnet.

Code samples

osc-cli api CreateNic PROFILE \
  --Description "string" \
  --DryRun False \
  --PrivateIps '[ \
      { \
        "IsPrimary": True, \
        "PrivateIp": "string" \
      } \
    ]' \
  --SecurityGroupIds '["string"]' \
  --SubnetId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateNic \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "Description": "string", \
  "DryRun": true, \
  "PrivateIps": [ \
    { \
      "IsPrimary": true, \
      "PrivateIp": "string" \
    } \
  ], \
  "SecurityGroupIds": [ \
    "string" \
  ], \
  "SubnetId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "Description": "string",
  "DryRun": False,
  "PrivateIps": [ 
    { 
      "IsPrimary": True, 
      "PrivateIp": "string" 
    } 
  ],
  "SecurityGroupIds": ["string"],
  "SubnetId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateNic', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
Description string false A description for the NIC.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
PrivateIps [PrivateIpLight] false The primary private IP for the NIC.
» IsPrimary boolean false If true, the IP is the primary private IP of the NIC.
» PrivateIp string false The private IP of the NIC.
SecurityGroupIds [string] false One or more IDs of security groups for the NIC.
SubnetId string true The ID of the Subnet in which you want to create the NIC.

Detailed descriptions

PrivateIps: The primary private IP for the NIC.
This IP must be within the IP range of the Subnet that you specify with the SubnetId attribute.
If you do not specify this attribute, a random private IP is selected within the IP range of the Subnet.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateNicResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "Nic": {
    "AccountId": "string",
    "Description": "string",
    "IsSourceDestChecked": true,
    "LinkNic": {
      "DeleteOnVmDeletion": true,
      "DeviceNumber": 0,
      "LinkNicId": "string",
      "State": "string",
      "VmAccountId": "string",
      "VmId": "string"
    },
    "LinkPublicIp": {
      "LinkPublicIpId": "string",
      "PublicDnsName": "string",
      "PublicIp": "string",
      "PublicIpAccountId": "string",
      "PublicIpId": "string"
    },
    "MacAddress": "string",
    "NetId": "string",
    "NicId": "string",
    "PrivateDnsName": "string",
    "PrivateIps": [
      {
        "IsPrimary": true,
        "LinkPublicIp": {
          "LinkPublicIpId": "string",
          "PublicDnsName": "string",
          "PublicIp": "string",
          "PublicIpAccountId": "string",
          "PublicIpId": "string"
        },
        "PrivateDnsName": "string",
        "PrivateIp": "string"
      }
    ],
    "SecurityGroups": [
      {
        "SecurityGroupId": "string",
        "SecurityGroupName": "string"
      }
    ],
    "State": "string",
    "SubnetId": "string",
    "SubregionName": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteNic

POST /DeleteNic

Deletes the specified network interface card (NIC).
The network interface must not be attached to any virtual machine (VM).

Code samples

osc-cli api DeleteNic PROFILE \
  --DryRun False \
  --NicId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteNic \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "NicId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "NicId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteNic', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NicId string true The ID of the NIC you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteNicResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

LinkNic

POST /LinkNic

Attaches a network interface card (NIC) to a virtual machine (VM).
The interface and the VM must be in the same Subregion. The VM can be either running or stopped. The NIC must be in the available state.

Code samples

osc-cli api LinkNic PROFILE \
  --DeviceNumber 0 \
  --DryRun False \
  --NicId "string" \
  --VmId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/LinkNic \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DeviceNumber": 0, \
  "DryRun": true, \
  "NicId": "string", \
  "VmId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DeviceNumber": 0,
  "DryRun": False,
  "NicId": "string",
  "VmId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/LinkNic', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DeviceNumber integer true The index of the VM device for the NIC attachment (between 1 and 7, both included).
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NicId string true The ID of the NIC you want to attach.
VmId string true The ID of the VM to which you want to attach the NIC.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). LinkNicResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "LinkNicId": "string",
  "ResponseContext": {
    "RequestId": "string"
  }
}

LinkPrivateIps

POST /LinkPrivateIps

Assigns one or more secondary private IPs to a specified network interface card (NIC). This action is only available in a Net. The private IPs to be assigned can be added individually using the PrivateIps parameter, or you can specify the number of private IPs to be automatically chosen within the Subnet range using the SecondaryPrivateIpCount parameter. You can specify only one of these two parameters. If none of these parameters are specified, a private IP is chosen within the Subnet range.

Code samples

osc-cli api LinkPrivateIps PROFILE \
  --AllowRelink True \
  --DryRun False \
  --NicId "string" \
  --PrivateIps '["string"]' \
  --SecondaryPrivateIpCount 0 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/LinkPrivateIps \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "AllowRelink": true, \
  "DryRun": true, \
  "NicId": "string", \
  "PrivateIps": [ \
    "string" \
  ], \
  "SecondaryPrivateIpCount": 0 \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "AllowRelink": True,
  "DryRun": False,
  "NicId": "string",
  "PrivateIps": ["string"],
  "SecondaryPrivateIpCount": 0
}

r = requests.post('https://api.{region}.outscale.com/api/v1/LinkPrivateIps', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
AllowRelink boolean false If true, allows an IP that is already assigned to another NIC in the same Subnet to be assigned to the NIC you specified.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NicId string true The ID of the NIC.
PrivateIps [string] false The secondary private IP or IPs you want to assign to the NIC within the IP range of the Subnet.
SecondaryPrivateIpCount integer false The number of secondary private IPs to assign to the NIC.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). LinkPrivateIpsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadNics

POST /ReadNics

Lists one or more network interface cards (NICs).
A NIC is a virtual network interface that you can attach to a virtual machine (VM) in a Net.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadNics PROFILE \
  --DryRun False \
  --Filters '{ \
      "Descriptions": ["string"], \
      "IsSourceDestCheck": True, \
      "LinkNicDeleteOnVmDeletion": True, \
      "LinkNicDeviceNumbers": [0], \
      "LinkNicLinkNicIds": ["string"], \
      "LinkNicStates": ["string"], \
      "LinkNicVmAccountIds": ["string"], \
      "LinkNicVmIds": ["string"], \
      "LinkPublicIpAccountIds": ["string"], \
      "LinkPublicIpLinkPublicIpIds": ["string"], \
      "LinkPublicIpPublicIpIds": ["string"], \
      "LinkPublicIpPublicIps": ["string"], \
      "MacAddresses": ["string"], \
      "NetIds": ["string"], \
      "NicIds": ["string"], \
      "PrivateDnsNames": ["string"], \
      "PrivateIpsLinkPublicIpAccountIds": ["string"], \
      "PrivateIpsLinkPublicIpPublicIps": ["string"], \
      "PrivateIpsPrimaryIp": True, \
      "PrivateIpsPrivateIps": ["string"], \
      "SecurityGroupIds": ["string"], \
      "SecurityGroupNames": ["string"], \
      "States": ["string"], \
      "SubnetIds": ["string"], \
      "SubregionNames": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadNics \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "Descriptions": [ \
      "string" \
    ], \
    "IsSourceDestCheck": true, \
    "LinkNicDeleteOnVmDeletion": true, \
    "LinkNicDeviceNumbers": [ \
      0 \
    ], \
    "LinkNicLinkNicIds": [ \
      "string" \
    ], \
    "LinkNicStates": [ \
      "string" \
    ], \
    "LinkNicVmAccountIds": [ \
      "string" \
    ], \
    "LinkNicVmIds": [ \
      "string" \
    ], \
    "LinkPublicIpAccountIds": [ \
      "string" \
    ], \
    "LinkPublicIpLinkPublicIpIds": [ \
      "string" \
    ], \
    "LinkPublicIpPublicIpIds": [ \
      "string" \
    ], \
    "LinkPublicIpPublicIps": [ \
      "string" \
    ], \
    "MacAddresses": [ \
      "string" \
    ], \
    "NetIds": [ \
      "string" \
    ], \
    "NicIds": [ \
      "string" \
    ], \
    "PrivateDnsNames": [ \
      "string" \
    ], \
    "PrivateIpsLinkPublicIpAccountIds": [ \
      "string" \
    ], \
    "PrivateIpsLinkPublicIpPublicIps": [ \
      "string" \
    ], \
    "PrivateIpsPrimaryIp": true, \
    "PrivateIpsPrivateIps": [ \
      "string" \
    ], \
    "SecurityGroupIds": [ \
      "string" \
    ], \
    "SecurityGroupNames": [ \
      "string" \
    ], \
    "States": [ \
      "string" \
    ], \
    "SubnetIds": [ \
      "string" \
    ], \
    "SubregionNames": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "Descriptions": ["string"], 
    "IsSourceDestCheck": True, 
    "LinkNicDeleteOnVmDeletion": True, 
    "LinkNicDeviceNumbers": [0], 
    "LinkNicLinkNicIds": ["string"], 
    "LinkNicStates": ["string"], 
    "LinkNicVmAccountIds": ["string"], 
    "LinkNicVmIds": ["string"], 
    "LinkPublicIpAccountIds": ["string"], 
    "LinkPublicIpLinkPublicIpIds": ["string"], 
    "LinkPublicIpPublicIpIds": ["string"], 
    "LinkPublicIpPublicIps": ["string"], 
    "MacAddresses": ["string"], 
    "NetIds": ["string"], 
    "NicIds": ["string"], 
    "PrivateDnsNames": ["string"], 
    "PrivateIpsLinkPublicIpAccountIds": ["string"], 
    "PrivateIpsLinkPublicIpPublicIps": ["string"], 
    "PrivateIpsPrimaryIp": True, 
    "PrivateIpsPrivateIps": ["string"], 
    "SecurityGroupIds": ["string"], 
    "SecurityGroupNames": ["string"], 
    "States": ["string"], 
    "SubnetIds": ["string"], 
    "SubregionNames": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadNics', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersNic false One or more filters.
» Descriptions [string] false The descriptions of the NICs.
» IsSourceDestCheck boolean false Whether the source/destination checking is enabled (true) or disabled (false).
» LinkNicDeleteOnVmDeletion boolean false Whether the NICs are deleted when the VMs they are attached to are terminated.
» LinkNicDeviceNumbers [integer] false The device numbers the NICs are attached to.
» LinkNicLinkNicIds [string] false The attachment IDs of the NICs.
» LinkNicStates [string] false The states of the attachments.
» LinkNicVmAccountIds [string] false The account IDs of the owners of the VMs the NICs are attached to.
» LinkNicVmIds [string] false The IDs of the VMs the NICs are attached to.
» LinkPublicIpAccountIds [string] false The account IDs of the owners of the public IPs associated with the NICs.
» LinkPublicIpLinkPublicIpIds [string] false The association IDs returned when the public IPs were associated with the NICs.
» LinkPublicIpPublicIpIds [string] false The allocation IDs returned when the public IPs were allocated to their accounts.
» LinkPublicIpPublicIps [string] false The public IPs associated with the NICs.
» MacAddresses [string] false The Media Access Control (MAC) addresses of the NICs.
» NetIds [string] false The IDs of the Nets where the NICs are located.
» NicIds [string] false The IDs of the NICs.
» PrivateDnsNames [string] false The private DNS names associated with the primary private IPs.
» PrivateIpsLinkPublicIpAccountIds [string] false The account IDs of the owner of the public IPs associated with the private IPs.
» PrivateIpsLinkPublicIpPublicIps [string] false The public IPs associated with the private IPs.
» PrivateIpsPrimaryIp boolean false Whether the private IP is the primary IP associated with the NIC.
» PrivateIpsPrivateIps [string] false The private IPs of the NICs.
» SecurityGroupIds [string] false The IDs of the security groups associated with the NICs.
» SecurityGroupNames [string] false The names of the security groups associated with the NICs.
» States [string] false The states of the NICs.
» SubnetIds [string] false The IDs of the Subnets for the NICs.
» SubregionNames [string] false The Subregions where the NICs are located.
» TagKeys [string] false The keys of the tags associated with the NICs.
» TagValues [string] false The values of the tags associated with the NICs.
» Tags [string] false The key/value combination of the tags associated with the NICs, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadNicsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "Nics": [
    {
      "AccountId": "string",
      "Description": "string",
      "IsSourceDestChecked": true,
      "LinkNic": {
        "DeleteOnVmDeletion": true,
        "DeviceNumber": 0,
        "LinkNicId": "string",
        "State": "string",
        "VmAccountId": "string",
        "VmId": "string"
      },
      "LinkPublicIp": {
        "LinkPublicIpId": "string",
        "PublicDnsName": "string",
        "PublicIp": "string",
        "PublicIpAccountId": "string",
        "PublicIpId": "string"
      },
      "MacAddress": "string",
      "NetId": "string",
      "NicId": "string",
      "PrivateDnsName": "string",
      "PrivateIps": [
        {
          "IsPrimary": true,
          "LinkPublicIp": {
            "LinkPublicIpId": "string",
            "PublicDnsName": "string",
            "PublicIp": "string",
            "PublicIpAccountId": "string",
            "PublicIpId": "string"
          },
          "PrivateDnsName": "string",
          "PrivateIp": "string"
        }
      ],
      "SecurityGroups": [
        {
          "SecurityGroupId": "string",
          "SecurityGroupName": "string"
        }
      ],
      "State": "string",
      "SubnetId": "string",
      "SubregionName": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ]
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

UnlinkNic

POST /UnlinkNic

Detaches a network interface card (NIC) from a virtual machine (VM).
The primary NIC cannot be detached.

Code samples

osc-cli api UnlinkNic PROFILE \
  --DryRun False \
  --LinkNicId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UnlinkNic \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "LinkNicId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "LinkNicId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UnlinkNic', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LinkNicId string true The ID of the attachment operation.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UnlinkNicResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

UnlinkPrivateIps

POST /UnlinkPrivateIps

Unassigns one or more secondary private IPs from a network interface card (NIC).

Code samples

osc-cli api UnlinkPrivateIps PROFILE \
  --DryRun False \
  --NicId "string" \
  --PrivateIps '["string"]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UnlinkPrivateIps \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "NicId": "string", \
  "PrivateIps": [ \
    "string" \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "NicId": "string",
  "PrivateIps": ["string"]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UnlinkPrivateIps', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NicId string true The ID of the NIC.
PrivateIps [string] true One or more secondary private IPs you want to unassign from the NIC.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UnlinkPrivateIpsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

UpdateNic

POST /UpdateNic

Modifies the specified network interface card (NIC). You can specify only one attribute at a time.

Code samples

osc-cli api UpdateNic PROFILE \
  --Description "string" \
  --DryRun False \
  --LinkNic '{ \
      "DeleteOnVmDeletion": True, \
      "LinkNicId": "string" \
    }' \
  --NicId "string" \
  --SecurityGroupIds '["string"]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateNic \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "Description": "string", \
  "DryRun": true, \
  "LinkNic": { \
    "DeleteOnVmDeletion": true, \
    "LinkNicId": "string" \
  }, \
  "NicId": "string", \
  "SecurityGroupIds": [ \
    "string" \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "Description": "string",
  "DryRun": False,
  "LinkNic": { 
    "DeleteOnVmDeletion": True, 
    "LinkNicId": "string" 
  },
  "NicId": "string",
  "SecurityGroupIds": ["string"]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateNic', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
Description string false A new description for the NIC.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LinkNic LinkNicToUpdate false Information about the NIC attachment. If you are modifying the DeleteOnVmDeletion attribute, you must specify the ID of the NIC attachment.
» DeleteOnVmDeletion boolean false By default or if set to false, the NIC is detached from the VM when the VM is terminated. If true, the NIC is deleted.
» LinkNicId string false The ID of the NIC attachment.
NicId string true The ID of the NIC you want to modify.
SecurityGroupIds [string] false One or more IDs of security groups for the NIC.

Detailed descriptions

SecurityGroupIds: One or more IDs of security groups for the NIC.
You must specify at least one group, even if you use the default security group in the Net.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateNicResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "Nic": {
    "AccountId": "string",
    "Description": "string",
    "IsSourceDestChecked": true,
    "LinkNic": {
      "DeleteOnVmDeletion": true,
      "DeviceNumber": 0,
      "LinkNicId": "string",
      "State": "string",
      "VmAccountId": "string",
      "VmId": "string"
    },
    "LinkPublicIp": {
      "LinkPublicIpId": "string",
      "PublicDnsName": "string",
      "PublicIp": "string",
      "PublicIpAccountId": "string",
      "PublicIpId": "string"
    },
    "MacAddress": "string",
    "NetId": "string",
    "NicId": "string",
    "PrivateDnsName": "string",
    "PrivateIps": [
      {
        "IsPrimary": true,
        "LinkPublicIp": {
          "LinkPublicIpId": "string",
          "PublicDnsName": "string",
          "PublicIp": "string",
          "PublicIpAccountId": "string",
          "PublicIpId": "string"
        },
        "PrivateDnsName": "string",
        "PrivateIp": "string"
      }
    ],
    "SecurityGroups": [
      {
        "SecurityGroupId": "string",
        "SecurityGroupName": "string"
      }
    ],
    "State": "string",
    "SubnetId": "string",
    "SubregionName": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

ProductType

ReadProductTypes

POST /ReadProductTypes

Lists one or more product types.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadProductTypes PROFILE \
  --DryRun False \
  --Filters '{ \
      "ProductTypeIds": ["string"] \
    }' 

curl -X POST https://api.{region}.outscale.com/api/v1/ReadProductTypes \
  -H 'Content-Type: application/json' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "ProductTypeIds": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "ProductTypeIds": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadProductTypes', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersProductType false One or more filters.
» ProductTypeIds [string] false The IDs of the product types.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadProductTypesResponse

Example responses

200 Response

{
  "ProductTypes": [
    {
      "Description": "string",
      "ProductTypeId": "string",
      "Vendor": "string"
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

PublicIp

CreatePublicIp

POST /CreatePublicIp

Acquires a public IP for your account.
A public IP is a static IP designed for dynamic Cloud computing. It can be associated with a virtual machine (VM), a network interface card (NIC), a NAT service or an internet-facing load balancer.

Code samples

osc-cli api CreatePublicIp PROFILE \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreatePublicIp \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreatePublicIp', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreatePublicIpResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "PublicIp": {
    "LinkPublicIpId": "string",
    "NicAccountId": "string",
    "NicId": "string",
    "PrivateIp": "string",
    "PublicIp": "string",
    "PublicIpId": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ],
    "VmId": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeletePublicIp

POST /DeletePublicIp

Releases a public IP.
You can release a public IP associated with your account. This address is released in the public IP pool and can be used by someone else. Before releasing a public IP, ensure you updated all your resources communicating with this address.

Code samples

osc-cli api DeletePublicIp PROFILE \
  --DryRun False \
  --PublicIp "string" \
  --PublicIpId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeletePublicIp \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "PublicIp": "string", \
  "PublicIpId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "PublicIp": "string",
  "PublicIpId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeletePublicIp', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
PublicIp string false The public IP. In the public Cloud, this parameter is required.
PublicIpId string false The ID representing the association of the public IP with the VM or the NIC. In a Net, this parameter is required.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeletePublicIpResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

LinkPublicIp

POST /LinkPublicIp

Associates a public IP with a virtual machine (VM) or a network interface card (NIC). You can associate a public IP with only one VM or network interface at a time.
To associate a public IP in a Net, ensure that the Net has an Internet service attached. For more information, see the LinkInternetService method.
By default, the public IP is disassociated every time you stop and start the VM. For a persistent association, you can add the osc.fcu.eip.auto-attach tag to the VM with the public IP as value. For more information, see the CreateTags method.

[NOTE]
You can associate a public IP with a network address translation (NAT) service only when creating the NAT service. To modify its public IP, you need to delete the NAT service and re-create it with the new public IP. For more information, see the CreateNatService method.
To associate a public IP with an internet-facing load balancer, see the CreateLoadBalancer and UpdateLoadBalancer methods.

Code samples

osc-cli api LinkPublicIp PROFILE \
  --AllowRelink True \
  --DryRun False \
  --NicId "string" \
  --PrivateIp "string" \
  --PublicIp "string" \
  --PublicIpId "string" \
  --VmId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/LinkPublicIp \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "AllowRelink": true, \
  "DryRun": true, \
  "NicId": "string", \
  "PrivateIp": "string", \
  "PublicIp": "string", \
  "PublicIpId": "string", \
  "VmId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "AllowRelink": True,
  "DryRun": False,
  "NicId": "string",
  "PrivateIp": "string",
  "PublicIp": "string",
  "PublicIpId": "string",
  "VmId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/LinkPublicIp', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
AllowRelink boolean false If true, allows the public IP to be associated with the VM or NIC that you specify even if it is already associated with another VM or NIC. If false, prevents the public IP from being associated with the VM or NIC that you specify if it is already associated with another VM or NIC. (By default, true in the public Cloud, false in a Net.)
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NicId string false (Net only) The ID of the NIC. This parameter is required if the VM has more than one NIC attached. Otherwise, you need to specify the VmId parameter instead. You cannot specify both parameters at the same time.
PrivateIp string false (Net only) The primary or secondary private IP of the specified NIC. By default, the primary private IP.
PublicIp string false The public IP. This parameter is required unless you use the PublicIpId parameter.
PublicIpId string false The allocation ID of the public IP. This parameter is required unless you use the PublicIp parameter.
VmId string false The ID of the VM.

Detailed descriptions

VmId: The ID of the VM.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). LinkPublicIpResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "LinkPublicIpId": "string",
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadPublicIpRanges

POST /ReadPublicIpRanges

Gets the public IPv4 addresses in CIDR notation for the Region specified in the endpoint of the request. For more information, see Regions, Endpoints and Availability Zones Reference.

Code samples

osc-cli api ReadPublicIpRanges PROFILE \
  --DryRun False 

curl -X POST https://api.{region}.outscale.com/api/v1/ReadPublicIpRanges \
  -H 'Content-Type: application/json' \
  -d '{ \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}
params = { 
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadPublicIpRanges', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadPublicIpRangesResponse

Example responses

200 Response

{
  "PublicIps": [
    "string"
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadPublicIps

POST /ReadPublicIps

Lists one or more public IPs allocated to your account.
By default, this action returns information about all your public IPs: available or associated with a virtual machine (VM), a network interface card (NIC), a NAT service or an internet-facing load balancer.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadPublicIps PROFILE \
  --DryRun False \
  --Filters '{ \
      "LinkPublicIpIds": ["string"], \
      "NicAccountIds": ["string"], \
      "NicIds": ["string"], \
      "Placements": ["string"], \
      "PrivateIps": ["string"], \
      "PublicIpIds": ["string"], \
      "PublicIps": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"], \
      "VmIds": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadPublicIps \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "LinkPublicIpIds": [ \
      "string" \
    ], \
    "NicAccountIds": [ \
      "string" \
    ], \
    "NicIds": [ \
      "string" \
    ], \
    "Placements": [ \
      "string" \
    ], \
    "PrivateIps": [ \
      "string" \
    ], \
    "PublicIpIds": [ \
      "string" \
    ], \
    "PublicIps": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ], \
    "VmIds": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "LinkPublicIpIds": ["string"], 
    "NicAccountIds": ["string"], 
    "NicIds": ["string"], 
    "Placements": ["string"], 
    "PrivateIps": ["string"], 
    "PublicIpIds": ["string"], 
    "PublicIps": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"], 
    "VmIds": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadPublicIps', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersPublicIp false One or more filters.
» LinkPublicIpIds [string] false The IDs representing the associations of public IPs with VMs or NICs.
» NicAccountIds [string] false The account IDs of the owners of the NICs.
» NicIds [string] false The IDs of the NICs.
» Placements [string] false Whether the public IPs are for use in the public Cloud or in a Net.
» PrivateIps [string] false The private IPs associated with the public IPs.
» PublicIpIds [string] false The IDs of the public IPs.
» PublicIps [string] false The public IPs.
» TagKeys [string] false The keys of the tags associated with the public IPs.
» TagValues [string] false The values of the tags associated with the public IPs.
» Tags [string] false The key/value combination of the tags associated with the public IPs, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.
» VmIds [string] false The IDs of the VMs.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadPublicIpsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "PublicIps": [
    {
      "LinkPublicIpId": "string",
      "NicAccountId": "string",
      "NicId": "string",
      "PrivateIp": "string",
      "PublicIp": "string",
      "PublicIpId": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ],
      "VmId": "string"
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

UnlinkPublicIp

POST /UnlinkPublicIp

Disassociates a public IP from the virtual machine (VM) or network interface card (NIC) it is associated with.

[NOTE]
To disassociate the public IP from a NAT service, you need to delete the NAT service. For more information, see the DeleteNatService method.
To replace the public IP associated with an internet-facing load balancer, see the UpdateLoadBalancer method.

Code samples

osc-cli api UnlinkPublicIp PROFILE \
  --DryRun False \
  --LinkPublicIpId "string" \
  --PublicIp "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UnlinkPublicIp \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "LinkPublicIpId": "string", \
  "PublicIp": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "LinkPublicIpId": "string",
  "PublicIp": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UnlinkPublicIp', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LinkPublicIpId string false The ID representing the association of the public IP with the VM or the NIC. This parameter is required unless you use the PublicIp parameter.
PublicIp string false The public IP. This parameter is required unless you use the LinkPublicIpId parameter.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UnlinkPublicIpResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

Quota

ReadQuotas

POST /ReadQuotas

Lists one or more of your quotas.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadQuotas PROFILE \
  --DryRun False \
  --Filters '{ \
      "Collections": ["string"], \
      "QuotaNames": ["string"], \
      "QuotaTypes": ["string"], \
      "ShortDescriptions": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadQuotas \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "Collections": [ \
      "string" \
    ], \
    "QuotaNames": [ \
      "string" \
    ], \
    "QuotaTypes": [ \
      "string" \
    ], \
    "ShortDescriptions": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "Collections": ["string"], 
    "QuotaNames": ["string"], 
    "QuotaTypes": ["string"], 
    "ShortDescriptions": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadQuotas', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersQuota false One or more filters.
» Collections [string] false The group names of the quotas.
» QuotaNames [string] false The names of the quotas.
» QuotaTypes [string] false The resource IDs if these are resource-specific quotas, global if they are not.
» ShortDescriptions [string] false The description of the quotas.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadQuotasResponse

Example responses

200 Response

{
  "QuotaTypes": [
    {
      "QuotaType": "string",
      "Quotas": [
        {
          "AccountId": "string",
          "Description": "string",
          "MaxValue": 0,
          "Name": "string",
          "QuotaCollection": "string",
          "ShortDescription": "string",
          "UsedValue": 0
        }
      ]
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

Region

ReadRegions

POST /ReadRegions

Lists one or more Regions of the OUTSCALE Cloud.

Code samples

osc-cli api ReadRegions PROFILE \
  --DryRun False 

curl -X POST https://api.{region}.outscale.com/api/v1/ReadRegions \
  -H 'Content-Type: application/json' \
  -d '{ \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}
params = { 
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadRegions', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadRegionsResponse

Example responses

200 Response

{
  "Regions": [
    {
      "Endpoint": "string",
      "RegionName": "string"
    }
  ],
  "ResponseContext": {
    "RequestId": "string"
  }
}

Route

CreateRoute

POST /CreateRoute

Creates a route in a specified route table within a specified Net.
You must specify one of the following elements as the target:

The routing algorithm is based on the most specific match.

Code samples

osc-cli api CreateRoute PROFILE \
  --DestinationIpRange "string" \
  --DryRun False \
  --GatewayId "string" \
  --NatServiceId "string" \
  --NetPeeringId "string" \
  --NicId "string" \
  --RouteTableId "string" \
  --VmId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateRoute \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DestinationIpRange": "string", \
  "DryRun": true, \
  "GatewayId": "string", \
  "NatServiceId": "string", \
  "NetPeeringId": "string", \
  "NicId": "string", \
  "RouteTableId": "string", \
  "VmId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DestinationIpRange": "string",
  "DryRun": False,
  "GatewayId": "string",
  "NatServiceId": "string",
  "NetPeeringId": "string",
  "NicId": "string",
  "RouteTableId": "string",
  "VmId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateRoute', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DestinationIpRange string true The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24).
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
GatewayId string false The ID of an Internet service or virtual gateway attached to your Net.
NatServiceId string false The ID of a NAT service.
NetPeeringId string false The ID of a Net peering connection.
NicId string false The ID of a NIC.
RouteTableId string true The ID of the route table for which you want to create a route.
VmId string false The ID of a NAT VM in your Net (attached to exactly one NIC).

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateRouteResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "RouteTable": {
    "LinkRouteTables": [
      {
        "LinkRouteTableId": "string",
        "Main": true,
        "RouteTableId": "string",
        "SubnetId": "string"
      }
    ],
    "NetId": "string",
    "RoutePropagatingVirtualGateways": [
      {
        "VirtualGatewayId": "string"
      }
    ],
    "RouteTableId": "string",
    "Routes": [
      {
        "CreationMethod": "string",
        "DestinationIpRange": "string",
        "DestinationServiceId": "string",
        "GatewayId": "string",
        "NatServiceId": "string",
        "NetAccessPointId": "string",
        "NetPeeringId": "string",
        "NicId": "string",
        "State": "string",
        "VmAccountId": "string",
        "VmId": "string"
      }
    ],
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  }
}

DeleteRoute

POST /DeleteRoute

Deletes a route from a specified route table.

Code samples

osc-cli api DeleteRoute PROFILE \
  --DestinationIpRange "string" \
  --DryRun False \
  --RouteTableId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteRoute \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DestinationIpRange": "string", \
  "DryRun": true, \
  "RouteTableId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DestinationIpRange": "string",
  "DryRun": False,
  "RouteTableId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteRoute', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DestinationIpRange string true The exact IP range for the route.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
RouteTableId string true The ID of the route table from which you want to delete a route.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteRouteResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "RouteTable": {
    "LinkRouteTables": [
      {
        "LinkRouteTableId": "string",
        "Main": true,
        "RouteTableId": "string",
        "SubnetId": "string"
      }
    ],
    "NetId": "string",
    "RoutePropagatingVirtualGateways": [
      {
        "VirtualGatewayId": "string"
      }
    ],
    "RouteTableId": "string",
    "Routes": [
      {
        "CreationMethod": "string",
        "DestinationIpRange": "string",
        "DestinationServiceId": "string",
        "GatewayId": "string",
        "NatServiceId": "string",
        "NetAccessPointId": "string",
        "NetPeeringId": "string",
        "NicId": "string",
        "State": "string",
        "VmAccountId": "string",
        "VmId": "string"
      }
    ],
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  }
}

UpdateRoute

POST /UpdateRoute

Replaces an existing route within a route table in a Net.
You must specify one of the following elements as the target:

The routing algorithm is based on the most specific match.

Code samples

osc-cli api UpdateRoute PROFILE \
  --DestinationIpRange "string" \
  --DryRun False \
  --GatewayId "string" \
  --NatServiceId "string" \
  --NetPeeringId "string" \
  --NicId "string" \
  --RouteTableId "string" \
  --VmId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateRoute \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DestinationIpRange": "string", \
  "DryRun": true, \
  "GatewayId": "string", \
  "NatServiceId": "string", \
  "NetPeeringId": "string", \
  "NicId": "string", \
  "RouteTableId": "string", \
  "VmId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DestinationIpRange": "string",
  "DryRun": False,
  "GatewayId": "string",
  "NatServiceId": "string",
  "NetPeeringId": "string",
  "NicId": "string",
  "RouteTableId": "string",
  "VmId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateRoute', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DestinationIpRange string true The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24).
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
GatewayId string false The ID of an Internet service or virtual gateway attached to your Net.
NatServiceId string false The ID of a NAT service.
NetPeeringId string false The ID of a Net peering connection.
NicId string false The ID of a network interface card (NIC).
RouteTableId string true The ID of the route table.
VmId string false The ID of a NAT VM in your Net.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateRouteResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "RouteTable": {
    "LinkRouteTables": [
      {
        "LinkRouteTableId": "string",
        "Main": true,
        "RouteTableId": "string",
        "SubnetId": "string"
      }
    ],
    "NetId": "string",
    "RoutePropagatingVirtualGateways": [
      {
        "VirtualGatewayId": "string"
      }
    ],
    "RouteTableId": "string",
    "Routes": [
      {
        "CreationMethod": "string",
        "DestinationIpRange": "string",
        "DestinationServiceId": "string",
        "GatewayId": "string",
        "NatServiceId": "string",
        "NetAccessPointId": "string",
        "NetPeeringId": "string",
        "NicId": "string",
        "State": "string",
        "VmAccountId": "string",
        "VmId": "string"
      }
    ],
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  }
}

RouteTable

CreateRouteTable

POST /CreateRouteTable

Creates a route table for a specified Net.
You can then add routes and associate this route table with a Subnet.

Code samples

osc-cli api CreateRouteTable PROFILE \
  --DryRun False \
  --NetId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateRouteTable \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "NetId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "NetId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateRouteTable', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NetId string true The ID of the Net for which you want to create a route table.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateRouteTableResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "RouteTable": {
    "LinkRouteTables": [
      {
        "LinkRouteTableId": "string",
        "Main": true,
        "RouteTableId": "string",
        "SubnetId": "string"
      }
    ],
    "NetId": "string",
    "RoutePropagatingVirtualGateways": [
      {
        "VirtualGatewayId": "string"
      }
    ],
    "RouteTableId": "string",
    "Routes": [
      {
        "CreationMethod": "string",
        "DestinationIpRange": "string",
        "DestinationServiceId": "string",
        "GatewayId": "string",
        "NatServiceId": "string",
        "NetAccessPointId": "string",
        "NetPeeringId": "string",
        "NicId": "string",
        "State": "string",
        "VmAccountId": "string",
        "VmId": "string"
      }
    ],
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  }
}

DeleteRouteTable

POST /DeleteRouteTable

Deletes a specified route table.
Before deleting a route table, you must disassociate it from any Subnet. You cannot delete the main route table.

Code samples

osc-cli api DeleteRouteTable PROFILE \
  --DryRun False \
  --RouteTableId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteRouteTable \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "RouteTableId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "RouteTableId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteRouteTable', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
RouteTableId string true The ID of the route table you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteRouteTableResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

LinkRouteTable

POST /LinkRouteTable

Associates a Subnet with a route table.
The Subnet and the route table must be in the same Net. The traffic is routed according to the route table defined within this Net. You can associate a route table with several Subnets.

Code samples

osc-cli api LinkRouteTable PROFILE \
  --DryRun False \
  --RouteTableId "string" \
  --SubnetId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/LinkRouteTable \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "RouteTableId": "string", \
  "SubnetId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "RouteTableId": "string",
  "SubnetId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/LinkRouteTable', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
RouteTableId string true The ID of the route table.
SubnetId string true The ID of the Subnet.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). LinkRouteTableResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "LinkRouteTableId": "string",
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadRouteTables

POST /ReadRouteTables

Lists one or more of your route tables.
In your Net, each Subnet must be associated with a route table. If a Subnet is not explicitly associated with a route table, it is implicitly associated with the main route table of the Net.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadRouteTables PROFILE \
  --DryRun False \
  --Filters '{ \
      "LinkRouteTableIds": ["string"], \
      "LinkRouteTableLinkRouteTableIds": ["string"], \
      "LinkRouteTableMain": True, \
      "LinkSubnetIds": ["string"], \
      "NetIds": ["string"], \
      "RouteCreationMethods": ["string"], \
      "RouteDestinationIpRanges": ["string"], \
      "RouteDestinationServiceIds": ["string"], \
      "RouteGatewayIds": ["string"], \
      "RouteNatServiceIds": ["string"], \
      "RouteNetPeeringIds": ["string"], \
      "RouteStates": ["string"], \
      "RouteTableIds": ["string"], \
      "RouteVmIds": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadRouteTables \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "LinkRouteTableIds": [ \
      "string" \
    ], \
    "LinkRouteTableLinkRouteTableIds": [ \
      "string" \
    ], \
    "LinkRouteTableMain": true, \
    "LinkSubnetIds": [ \
      "string" \
    ], \
    "NetIds": [ \
      "string" \
    ], \
    "RouteCreationMethods": [ \
      "string" \
    ], \
    "RouteDestinationIpRanges": [ \
      "string" \
    ], \
    "RouteDestinationServiceIds": [ \
      "string" \
    ], \
    "RouteGatewayIds": [ \
      "string" \
    ], \
    "RouteNatServiceIds": [ \
      "string" \
    ], \
    "RouteNetPeeringIds": [ \
      "string" \
    ], \
    "RouteStates": [ \
      "string" \
    ], \
    "RouteTableIds": [ \
      "string" \
    ], \
    "RouteVmIds": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "LinkRouteTableIds": ["string"], 
    "LinkRouteTableLinkRouteTableIds": ["string"], 
    "LinkRouteTableMain": True, 
    "LinkSubnetIds": ["string"], 
    "NetIds": ["string"], 
    "RouteCreationMethods": ["string"], 
    "RouteDestinationIpRanges": ["string"], 
    "RouteDestinationServiceIds": ["string"], 
    "RouteGatewayIds": ["string"], 
    "RouteNatServiceIds": ["string"], 
    "RouteNetPeeringIds": ["string"], 
    "RouteStates": ["string"], 
    "RouteTableIds": ["string"], 
    "RouteVmIds": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadRouteTables', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersRouteTable false One or more filters.
» LinkRouteTableIds [string] false The IDs of the route tables involved in the associations.
» LinkRouteTableLinkRouteTableIds [string] false The IDs of the associations between the route tables and the Subnets.
» LinkRouteTableMain boolean false If true, the route tables are the main ones for their Nets.
» LinkSubnetIds [string] false The IDs of the Subnets involved in the associations.
» NetIds [string] false The IDs of the Nets for the route tables.
» RouteCreationMethods [string] false The methods used to create a route.
» RouteDestinationIpRanges [string] false The IP ranges specified in routes in the tables.
» RouteDestinationServiceIds [string] false The service IDs specified in routes in the tables.
» RouteGatewayIds [string] false The IDs of the gateways specified in routes in the tables.
» RouteNatServiceIds [string] false The IDs of the NAT services specified in routes in the tables.
» RouteNetPeeringIds [string] false The IDs of the Net peering connections specified in routes in the tables.
» RouteStates [string] false The states of routes in the route tables (active | blackhole). The blackhole state indicates that the target of the route is not available.
» RouteTableIds [string] false The IDs of the route tables.
» RouteVmIds [string] false The IDs of the VMs specified in routes in the tables.
» TagKeys [string] false The keys of the tags associated with the route tables.
» TagValues [string] false The values of the tags associated with the route tables.
» Tags [string] false The key/value combination of the tags associated with the route tables, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadRouteTablesResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "RouteTables": [
    {
      "LinkRouteTables": [
        {
          "LinkRouteTableId": "string",
          "Main": true,
          "RouteTableId": "string",
          "SubnetId": "string"
        }
      ],
      "NetId": "string",
      "RoutePropagatingVirtualGateways": [
        {
          "VirtualGatewayId": "string"
        }
      ],
      "RouteTableId": "string",
      "Routes": [
        {
          "CreationMethod": "string",
          "DestinationIpRange": "string",
          "DestinationServiceId": "string",
          "GatewayId": "string",
          "NatServiceId": "string",
          "NetAccessPointId": "string",
          "NetPeeringId": "string",
          "NicId": "string",
          "State": "string",
          "VmAccountId": "string",
          "VmId": "string"
        }
      ],
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ]
    }
  ]
}

UnlinkRouteTable

POST /UnlinkRouteTable

Disassociates a Subnet from a route table.
After disassociation, the Subnet can no longer use the routes in this route table, but uses the routes in the main route table of the Net instead.

Code samples

osc-cli api UnlinkRouteTable PROFILE \
  --DryRun False \
  --LinkRouteTableId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UnlinkRouteTable \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "LinkRouteTableId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "LinkRouteTableId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UnlinkRouteTable', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
LinkRouteTableId string true The ID of the association between the route table and the Subnet.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UnlinkRouteTableResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

SecurityGroup

CreateSecurityGroup

POST /CreateSecurityGroup

Creates a security group.
This action creates a security group either in the public Cloud or in a specified Net. By default, a default security group for use in the public Cloud and a default security group for use in a Net are created.
When launching a virtual machine (VM), if no security group is explicitly specified, the appropriate default security group is assigned to the VM. Default security groups include a default rule granting VMs network access to each other.
When creating a security group, you specify a name. Two security groups for use in the public Cloud or for use in a Net cannot have the same name.
You can have up to 500 security groups in the public Cloud. You can create up to 500 security groups per Net.
To add or remove rules, use the CreateSecurityGroupRule method.

Code samples

osc-cli api CreateSecurityGroup PROFILE \
  --Description "string" \
  --DryRun False \
  --NetId "string" \
  --SecurityGroupName "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateSecurityGroup \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "Description": "string", \
  "DryRun": true, \
  "NetId": "string", \
  "SecurityGroupName": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "Description": "string",
  "DryRun": False,
  "NetId": "string",
  "SecurityGroupName": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateSecurityGroup', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
Description string true A description for the security group, with a maximum length of 255 ASCII printable characters.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NetId string false The ID of the Net for the security group.
SecurityGroupName string true The name of the security group.

Detailed descriptions

SecurityGroupName: The name of the security group.
This name must not start with sg-.
This name must be unique and contain between 1 and 255 ASCII characters. Accented letters are not allowed.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateSecurityGroupResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "SecurityGroup": {
    "AccountId": "string",
    "Description": "string",
    "InboundRules": [
      {
        "FromPortRange": 0,
        "IpProtocol": "string",
        "IpRanges": [
          "string"
        ],
        "SecurityGroupsMembers": [
          {
            "AccountId": "string",
            "SecurityGroupId": "string",
            "SecurityGroupName": "string"
          }
        ],
        "ServiceIds": [
          "string"
        ],
        "ToPortRange": 0
      }
    ],
    "NetId": "string",
    "OutboundRules": [
      {
        "FromPortRange": 0,
        "IpProtocol": "string",
        "IpRanges": [
          "string"
        ],
        "SecurityGroupsMembers": [
          {
            "AccountId": "string",
            "SecurityGroupId": "string",
            "SecurityGroupName": "string"
          }
        ],
        "ServiceIds": [
          "string"
        ],
        "ToPortRange": 0
      }
    ],
    "SecurityGroupId": "string",
    "SecurityGroupName": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  }
}

DeleteSecurityGroup

POST /DeleteSecurityGroup

Deletes a specified security group.
You can specify either the name of the security group or its ID.
This action fails if the specified group is associated with a virtual machine (VM) or referenced by another security group.

Code samples

osc-cli api DeleteSecurityGroup PROFILE \
  --DryRun False \
  --SecurityGroupId "string" \
  --SecurityGroupName "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteSecurityGroup \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "SecurityGroupId": "string", \
  "SecurityGroupName": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "SecurityGroupId": "string",
  "SecurityGroupName": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteSecurityGroup', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
SecurityGroupId string false The ID of the security group you want to delete.
SecurityGroupName string false The name of the security group.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteSecurityGroupResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadSecurityGroups

POST /ReadSecurityGroups

Lists one or more security groups.
You can specify either the name of the security groups or their IDs.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadSecurityGroups PROFILE \
  --DryRun False \
  --Filters '{ \
      "AccountIds": ["string"], \
      "Descriptions": ["string"], \
      "InboundRuleAccountIds": ["string"], \
      "InboundRuleFromPortRanges": [0], \
      "InboundRuleIpRanges": ["string"], \
      "InboundRuleProtocols": ["string"], \
      "InboundRuleSecurityGroupIds": ["string"], \
      "InboundRuleSecurityGroupNames": ["string"], \
      "InboundRuleToPortRanges": [0], \
      "NetIds": ["string"], \
      "OutboundRuleAccountIds": ["string"], \
      "OutboundRuleFromPortRanges": [0], \
      "OutboundRuleIpRanges": ["string"], \
      "OutboundRuleProtocols": ["string"], \
      "OutboundRuleSecurityGroupIds": ["string"], \
      "OutboundRuleSecurityGroupNames": ["string"], \
      "OutboundRuleToPortRanges": [0], \
      "SecurityGroupIds": ["string"], \
      "SecurityGroupNames": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadSecurityGroups \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "AccountIds": [ \
      "string" \
    ], \
    "Descriptions": [ \
      "string" \
    ], \
    "InboundRuleAccountIds": [ \
      "string" \
    ], \
    "InboundRuleFromPortRanges": [ \
      0 \
    ], \
    "InboundRuleIpRanges": [ \
      "string" \
    ], \
    "InboundRuleProtocols": [ \
      "string" \
    ], \
    "InboundRuleSecurityGroupIds": [ \
      "string" \
    ], \
    "InboundRuleSecurityGroupNames": [ \
      "string" \
    ], \
    "InboundRuleToPortRanges": [ \
      0 \
    ], \
    "NetIds": [ \
      "string" \
    ], \
    "OutboundRuleAccountIds": [ \
      "string" \
    ], \
    "OutboundRuleFromPortRanges": [ \
      0 \
    ], \
    "OutboundRuleIpRanges": [ \
      "string" \
    ], \
    "OutboundRuleProtocols": [ \
      "string" \
    ], \
    "OutboundRuleSecurityGroupIds": [ \
      "string" \
    ], \
    "OutboundRuleSecurityGroupNames": [ \
      "string" \
    ], \
    "OutboundRuleToPortRanges": [ \
      0 \
    ], \
    "SecurityGroupIds": [ \
      "string" \
    ], \
    "SecurityGroupNames": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "AccountIds": ["string"], 
    "Descriptions": ["string"], 
    "InboundRuleAccountIds": ["string"], 
    "InboundRuleFromPortRanges": [0], 
    "InboundRuleIpRanges": ["string"], 
    "InboundRuleProtocols": ["string"], 
    "InboundRuleSecurityGroupIds": ["string"], 
    "InboundRuleSecurityGroupNames": ["string"], 
    "InboundRuleToPortRanges": [0], 
    "NetIds": ["string"], 
    "OutboundRuleAccountIds": ["string"], 
    "OutboundRuleFromPortRanges": [0], 
    "OutboundRuleIpRanges": ["string"], 
    "OutboundRuleProtocols": ["string"], 
    "OutboundRuleSecurityGroupIds": ["string"], 
    "OutboundRuleSecurityGroupNames": ["string"], 
    "OutboundRuleToPortRanges": [0], 
    "SecurityGroupIds": ["string"], 
    "SecurityGroupNames": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadSecurityGroups', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersSecurityGroup false One or more filters.
» AccountIds [string] false The account IDs of the owners of the security groups.
» Descriptions [string] false The descriptions of the security groups.
» InboundRuleAccountIds [string] false The account IDs that have been granted permissions.
» InboundRuleFromPortRanges [integer] false The beginnings of the port ranges for the TCP and UDP protocols, or the ICMP type numbers.
» InboundRuleIpRanges [string] false The IP ranges that have been granted permissions, in CIDR notation (for example, 10.0.0.0/24).
» InboundRuleProtocols [string] false The IP protocols for the permissions (tcp | udp | icmp, or a protocol number, or -1 for all protocols).
» InboundRuleSecurityGroupIds [string] false The IDs of the security groups that have been granted permissions.
» InboundRuleSecurityGroupNames [string] false The names of the security groups that have been granted permissions.
» InboundRuleToPortRanges [integer] false The ends of the port ranges for the TCP and UDP protocols, or the ICMP codes.
» NetIds [string] false The IDs of the Nets specified when the security groups were created.
» OutboundRuleAccountIds [string] false The account IDs that have been granted permissions.
» OutboundRuleFromPortRanges [integer] false The beginnings of the port ranges for the TCP and UDP protocols, or the ICMP type numbers.
» OutboundRuleIpRanges [string] false The IP ranges that have been granted permissions, in CIDR notation (for example, 10.0.0.0/24).
» OutboundRuleProtocols [string] false The IP protocols for the permissions (tcp | udp | icmp, or a protocol number, or -1 for all protocols).
» OutboundRuleSecurityGroupIds [string] false The IDs of the security groups that have been granted permissions.
» OutboundRuleSecurityGroupNames [string] false The names of the security groups that have been granted permissions.
» OutboundRuleToPortRanges [integer] false The ends of the port ranges for the TCP and UDP protocols, or the ICMP codes.
» SecurityGroupIds [string] false The IDs of the security groups.
» SecurityGroupNames [string] false The names of the security groups.
» TagKeys [string] false The keys of the tags associated with the security groups.
» TagValues [string] false The values of the tags associated with the security groups.
» Tags [string] false The key/value combination of the tags associated with the security groups, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadSecurityGroupsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "SecurityGroups": [
    {
      "AccountId": "string",
      "Description": "string",
      "InboundRules": [
        {
          "FromPortRange": 0,
          "IpProtocol": "string",
          "IpRanges": [
            "string"
          ],
          "SecurityGroupsMembers": [
            {
              "AccountId": "string",
              "SecurityGroupId": "string",
              "SecurityGroupName": "string"
            }
          ],
          "ServiceIds": [
            "string"
          ],
          "ToPortRange": 0
        }
      ],
      "NetId": "string",
      "OutboundRules": [
        {
          "FromPortRange": 0,
          "IpProtocol": "string",
          "IpRanges": [
            "string"
          ],
          "SecurityGroupsMembers": [
            {
              "AccountId": "string",
              "SecurityGroupId": "string",
              "SecurityGroupName": "string"
            }
          ],
          "ServiceIds": [
            "string"
          ],
          "ToPortRange": 0
        }
      ],
      "SecurityGroupId": "string",
      "SecurityGroupName": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ]
    }
  ]
}

SecurityGroupRule

CreateSecurityGroupRule

POST /CreateSecurityGroupRule

Configures the rules for a security group.
The modifications are effective at virtual machine (VM) level as quickly as possible, but a small delay may occur.

You can add one or more egress rules to a security group for use with a Net.
It allows VMs to send traffic to either one or more destination IP ranges or destination security groups for the same Net.
We recommend using a set of IP permissions to authorize outbound access to a destination security group. We also recommended this method to create a rule with a specific IP protocol and a specific port range. In a set of IP permissions, we recommend to specify the the protocol.

You can also add one or more ingress rules to a security group.
In the public Cloud, this action allows one or more IP ranges to access a security group for your account, or allows one or more security groups (source groups) to access a security group for your own OUTSCALE account or another one.
In a Net, this action allows one or more IP ranges to access a security group for your Net, or allows one or more other security groups (source groups) to access a security group for your Net. All the security groups must be for the same Net.

[NOTE]
By default, traffic between two security groups is allowed through both public and private IPs. To restrict it to private IPs only, contact our Support team: support@outscale.com.

Code samples

osc-cli api CreateSecurityGroupRule PROFILE \
  --DryRun False \
  --Flow "string" \
  --FromPortRange 0 \
  --IpProtocol "string" \
  --IpRange "string" \
  --Rules '[ \
      { \
        "FromPortRange": 0, \
        "IpProtocol": "string", \
        "IpRanges": ["string"], \
        "SecurityGroupsMembers": [{"AccountId": "string", "SecurityGroupId": "string", "SecurityGroupName": "string"}], \
        "ServiceIds": ["string"], \
        "ToPortRange": 0 \
      } \
    ]' \
  --SecurityGroupAccountIdToLink "string" \
  --SecurityGroupId "string" \
  --SecurityGroupNameToLink "string" \
  --ToPortRange 0 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateSecurityGroupRule \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Flow": "string", \
  "FromPortRange": 0, \
  "IpProtocol": "string", \
  "IpRange": "string", \
  "Rules": [ \
    { \
      "FromPortRange": 0, \
      "IpProtocol": "string", \
      "IpRanges": [ \
        "string" \
      ], \
      "SecurityGroupsMembers": [ \
        { \
          "AccountId": "string", \
          "SecurityGroupId": "string", \
          "SecurityGroupName": "string" \
        } \
      ], \
      "ServiceIds": [ \
        "string" \
      ], \
      "ToPortRange": 0 \
    } \
  ], \
  "SecurityGroupAccountIdToLink": "string", \
  "SecurityGroupId": "string", \
  "SecurityGroupNameToLink": "string", \
  "ToPortRange": 0 \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Flow": "string",
  "FromPortRange": 0,
  "IpProtocol": "string",
  "IpRange": "string",
  "Rules": [ 
    { 
      "FromPortRange": 0, 
      "IpProtocol": "string", 
      "IpRanges": ["string"], 
      "SecurityGroupsMembers": [ 
        {"AccountId": "string", "SecurityGroupId": "string", "SecurityGroupName": "string"} 
      ], 
      "ServiceIds": ["string"], 
      "ToPortRange": 0 
    } 
  ],
  "SecurityGroupAccountIdToLink": "string",
  "SecurityGroupId": "string",
  "SecurityGroupNameToLink": "string",
  "ToPortRange": 0
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateSecurityGroupRule', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Flow string true The direction of the flow: Inbound or Outbound. You can specify Outbound for Nets only.
FromPortRange integer false The beginning of the port range for the TCP and UDP protocols, or an ICMP type number.
IpProtocol string false The IP protocol name (tcp, udp, icmp, or -1 for all protocols). By default, -1. In a Net, this can also be an IP protocol number. For more information, see the IANA.org website.
IpRange string false The IP range for the security group rule, in CIDR notation (for example, 10.0.0.0/16).
Rules [SecurityGroupRule] false Information about the security group rule to create.
» FromPortRange integer false The beginning of the port range for the TCP and UDP protocols, or an ICMP type number.
» IpProtocol string false The IP protocol name (tcp, udp, icmp, or -1 for all protocols). By default, -1. In a Net, this can also be an IP protocol number. For more information, see the IANA.org website.
» IpRanges [string] false One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16).
» SecurityGroupsMembers [SecurityGroupsMember] false Information about one or more members of a security group.
»» AccountId string false The account ID of a user.
»» SecurityGroupId string false The ID of the security group.
»» SecurityGroupName string false The name of the security group.
» ServiceIds [string] false One or more service IDs to allow traffic from a Net to access the corresponding OUTSCALE services. For more information, see ReadNetAccessPointServices.
» ToPortRange integer false The end of the port range for the TCP and UDP protocols, or an ICMP type number.
SecurityGroupAccountIdToLink string false The account ID of the owner of the security group for which you want to create a rule.
SecurityGroupId string true The ID of the security group for which you want to create a rule.
SecurityGroupNameToLink string false The ID of the source security group. If you are in the Public Cloud, you can also specify the name of the source security group.
ToPortRange integer false The end of the port range for the TCP and UDP protocols, or an ICMP type number.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateSecurityGroupRuleResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "SecurityGroup": {
    "AccountId": "string",
    "Description": "string",
    "InboundRules": [
      {
        "FromPortRange": 0,
        "IpProtocol": "string",
        "IpRanges": [
          "string"
        ],
        "SecurityGroupsMembers": [
          {
            "AccountId": "string",
            "SecurityGroupId": "string",
            "SecurityGroupName": "string"
          }
        ],
        "ServiceIds": [
          "string"
        ],
        "ToPortRange": 0
      }
    ],
    "NetId": "string",
    "OutboundRules": [
      {
        "FromPortRange": 0,
        "IpProtocol": "string",
        "IpRanges": [
          "string"
        ],
        "SecurityGroupsMembers": [
          {
            "AccountId": "string",
            "SecurityGroupId": "string",
            "SecurityGroupName": "string"
          }
        ],
        "ServiceIds": [
          "string"
        ],
        "ToPortRange": 0
      }
    ],
    "SecurityGroupId": "string",
    "SecurityGroupName": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  }
}

DeleteSecurityGroupRule

POST /DeleteSecurityGroupRule

Deletes one or more inbound or outbound rules from a security group. For the rule to be deleted, the values specified in the deletion request must exactly match the value of the existing rule.
In case of TCP and UDP protocols, you have to indicate the destination port or range of ports. In case of ICMP protocol, you have to specify the ICMP type and code.
Rules (IP permissions) consist of the protocol, IP range or source security group.
To remove outbound access to a destination security group, we recommend to use a set of IP permissions. We also recommend to specify the protocol in a set of IP permissions.

Code samples

osc-cli api DeleteSecurityGroupRule PROFILE \
  --DryRun False \
  --Flow "string" \
  --FromPortRange 0 \
  --IpProtocol "string" \
  --IpRange "string" \
  --Rules '[ \
      { \
        "FromPortRange": 0, \
        "IpProtocol": "string", \
        "IpRanges": ["string"], \
        "SecurityGroupsMembers": [{"AccountId": "string", "SecurityGroupId": "string", "SecurityGroupName": "string"}], \
        "ServiceIds": ["string"], \
        "ToPortRange": 0 \
      } \
    ]' \
  --SecurityGroupAccountIdToUnlink "string" \
  --SecurityGroupId "string" \
  --SecurityGroupNameToUnlink "string" \
  --ToPortRange 0 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteSecurityGroupRule \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Flow": "string", \
  "FromPortRange": 0, \
  "IpProtocol": "string", \
  "IpRange": "string", \
  "Rules": [ \
    { \
      "FromPortRange": 0, \
      "IpProtocol": "string", \
      "IpRanges": [ \
        "string" \
      ], \
      "SecurityGroupsMembers": [ \
        { \
          "AccountId": "string", \
          "SecurityGroupId": "string", \
          "SecurityGroupName": "string" \
        } \
      ], \
      "ServiceIds": [ \
        "string" \
      ], \
      "ToPortRange": 0 \
    } \
  ], \
  "SecurityGroupAccountIdToUnlink": "string", \
  "SecurityGroupId": "string", \
  "SecurityGroupNameToUnlink": "string", \
  "ToPortRange": 0 \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Flow": "string",
  "FromPortRange": 0,
  "IpProtocol": "string",
  "IpRange": "string",
  "Rules": [ 
    { 
      "FromPortRange": 0, 
      "IpProtocol": "string", 
      "IpRanges": ["string"], 
      "SecurityGroupsMembers": [ 
        {"AccountId": "string", "SecurityGroupId": "string", "SecurityGroupName": "string"} 
      ], 
      "ServiceIds": ["string"], 
      "ToPortRange": 0 
    } 
  ],
  "SecurityGroupAccountIdToUnlink": "string",
  "SecurityGroupId": "string",
  "SecurityGroupNameToUnlink": "string",
  "ToPortRange": 0
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteSecurityGroupRule', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Flow string true The direction of the flow: Inbound or Outbound. You can specify Outbound for Nets only.
FromPortRange integer false The beginning of the port range for the TCP and UDP protocols, or an ICMP type number.
IpProtocol string false The IP protocol name (tcp, udp, icmp, or -1 for all protocols). By default, -1. In a Net, this can also be an IP protocol number. For more information, see the IANA.org website.
IpRange string false The IP range for the security group rule, in CIDR notation (for example, 10.0.0.0/16).
Rules [SecurityGroupRule] false One or more rules you want to delete from the security group.
» FromPortRange integer false The beginning of the port range for the TCP and UDP protocols, or an ICMP type number.
» IpProtocol string false The IP protocol name (tcp, udp, icmp, or -1 for all protocols). By default, -1. In a Net, this can also be an IP protocol number. For more information, see the IANA.org website.
» IpRanges [string] false One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16).
» SecurityGroupsMembers [SecurityGroupsMember] false Information about one or more members of a security group.
»» AccountId string false The account ID of a user.
»» SecurityGroupId string false The ID of the security group.
»» SecurityGroupName string false The name of the security group.
» ServiceIds [string] false One or more service IDs to allow traffic from a Net to access the corresponding OUTSCALE services. For more information, see ReadNetAccessPointServices.
» ToPortRange integer false The end of the port range for the TCP and UDP protocols, or an ICMP type number.
SecurityGroupAccountIdToUnlink string false The account ID of the owner of the security group you want to delete a rule from.
SecurityGroupId string true The ID of the security group you want to delete a rule from.
SecurityGroupNameToUnlink string false The ID of the source security group. If you are in the Public Cloud, you can also specify the name of the source security group.
ToPortRange integer false The end of the port range for the TCP and UDP protocols, or an ICMP type number.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteSecurityGroupRuleResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "SecurityGroup": {
    "AccountId": "string",
    "Description": "string",
    "InboundRules": [
      {
        "FromPortRange": 0,
        "IpProtocol": "string",
        "IpRanges": [
          "string"
        ],
        "SecurityGroupsMembers": [
          {
            "AccountId": "string",
            "SecurityGroupId": "string",
            "SecurityGroupName": "string"
          }
        ],
        "ServiceIds": [
          "string"
        ],
        "ToPortRange": 0
      }
    ],
    "NetId": "string",
    "OutboundRules": [
      {
        "FromPortRange": 0,
        "IpProtocol": "string",
        "IpRanges": [
          "string"
        ],
        "SecurityGroupsMembers": [
          {
            "AccountId": "string",
            "SecurityGroupId": "string",
            "SecurityGroupName": "string"
          }
        ],
        "ServiceIds": [
          "string"
        ],
        "ToPortRange": 0
      }
    ],
    "SecurityGroupId": "string",
    "SecurityGroupName": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  }
}

ServerCertificate

CreateServerCertificate

POST /CreateServerCertificate

Creates a server certificate and its matching private key.

These elements can be used with other services (for example, to configure SSL termination on load balancers).

You can also specify the chain of intermediate certification authorities if your certificate is not directly signed by a root one. You can specify multiple intermediate certification authorities in the CertificateChain parameter. To do so, concatenate all certificates in the correct order (the first certificate must be the authority of your certificate, the second must the the authority of the first one, and so on).

The private key must be a RSA key in PKCS1 form. To check this, open the PEM file and ensure its header reads as follows: BEGIN RSA PRIVATE KEY.

[IMPORTANT]

This private key must not be protected by a password or a passphrase.

Code samples

osc-cli api CreateServerCertificate PROFILE \
  --Body "string" \
  --Chain "string" \
  --DryRun False \
  --Name "string" \
  --Path "string" \
  --PrivateKey "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateServerCertificate \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "Body": "string", \
  "Chain": "string", \
  "DryRun": true, \
  "Name": "string", \
  "Path": "string", \
  "PrivateKey": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "Body": "string",
  "Chain": "string",
  "DryRun": False,
  "Name": "string",
  "Path": "string",
  "PrivateKey": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateServerCertificate', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
Body string true The PEM-encoded X509 certificate.
Chain string false The PEM-encoded intermediate certification authorities.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Name string true A unique name for the certificate. Constraints: 1-128 alphanumeric characters, pluses (+), equals (=), commas (,), periods (.), at signs (@), minuses (-), or underscores (_).
Path string false The path to the server certificate, set to a slash (/) if not specified.
PrivateKey string true The PEM-encoded private key matching the certificate.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateServerCertificateResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "ServerCertificate": {
    "ExpirationDate": "2019-08-24",
    "Id": "string",
    "Name": "string",
    "Path": "string",
    "UploadDate": "2019-08-24"
  }
}

DeleteServerCertificate

POST /DeleteServerCertificate

Deletes a specified server certificate.

Code samples

osc-cli api DeleteServerCertificate PROFILE \
  --DryRun False \
  --Name "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteServerCertificate \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Name": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Name": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteServerCertificate', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Name string true The name of the server certificate you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteServerCertificateResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadServerCertificates

POST /ReadServerCertificates

Lists your server certificates.

Code samples

osc-cli api ReadServerCertificates PROFILE \
  --DryRun False \
  --Filters '{ \
      "Paths": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadServerCertificates \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "Paths": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "Paths": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadServerCertificates', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersServerCertificate false One or more filters.
» Paths [string] false The paths to the server certificates.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadServerCertificatesResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "ServerCertificates": [
    {
      "ExpirationDate": "2019-08-24",
      "Id": "string",
      "Name": "string",
      "Path": "string",
      "UploadDate": "2019-08-24"
    }
  ]
}

UpdateServerCertificate

POST /UpdateServerCertificate

Modifies the name and/or the path of a specified server certificate.

Code samples

osc-cli api UpdateServerCertificate PROFILE \
  --DryRun False \
  --Name "string" \
  --NewName "string" \
  --NewPath "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateServerCertificate \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Name": "string", \
  "NewName": "string", \
  "NewPath": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Name": "string",
  "NewName": "string",
  "NewPath": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateServerCertificate', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Name string true The name of the server certificate you want to modify.
NewName string false A new name for the server certificate.
NewPath string false A new path for the server certificate.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateServerCertificateResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "ServerCertificate": {
    "ExpirationDate": "2019-08-24",
    "Id": "string",
    "Name": "string",
    "Path": "string",
    "UploadDate": "2019-08-24"
  }
}

Snapshot

CreateSnapshot

POST /CreateSnapshot

Creates a snapshot of a Block storage Unit (BSU) volume.
Snapshots are point-in-time images of a volume you can use to back up your data or to create replicas of this volume at the time the snapshot was created.

You can also use this method to copy a snapshot to your account, from an account in the same Region.
To do so, the owner of the source snapshot must share it with your account. For more information about how to share a snapshot with another account, see UpdateSnapshot.
The copy of the source snapshot is independent and belongs to you.

To copy a snapshot between accounts in different Regions, the owner of the source snapshot must export it to an OUTSCALE Object Storage (OOS) bucket using the CreateSnapshotExportTask method. You then need to import it from the bucket to create a copy of this snapshot in your account.
You can import a snapshot using a pre-signed URL. You do not need any permission for this snapshot, or the bucket in which it is contained. The pre-signed URL is valid for seven days (you can regenerate a new one if needed).

Code samples

osc-cli api CreateSnapshot PROFILE \
  --Description "string" \
  --DryRun False \
  --FileLocation "string" \
  --SnapshotSize 0 \
  --SourceRegionName "string" \
  --SourceSnapshotId "string" \
  --VolumeId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateSnapshot \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "Description": "string", \
  "DryRun": true, \
  "FileLocation": "string", \
  "SnapshotSize": 0, \
  "SourceRegionName": "string", \
  "SourceSnapshotId": "string", \
  "VolumeId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "Description": "string",
  "DryRun": False,
  "FileLocation": "string",
  "SnapshotSize": 0,
  "SourceRegionName": "string",
  "SourceSnapshotId": "string",
  "VolumeId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateSnapshot', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
Description string false A description for the snapshot.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
FileLocation string false The pre-signed URL of the snapshot you want to import from the bucket.
SnapshotSize integer(int64) false The size of the snapshot you want to create in your account, in bytes. This size must be greater than or equal to the size of the original, uncompressed snapshot.
SourceRegionName string false The name of the source Region, which must be the same as the Region of your account.
SourceSnapshotId string false The ID of the snapshot you want to copy.
VolumeId string false The ID of the volume you want to create a snapshot of.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateSnapshotResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Snapshot": {
    "AccountAlias": "string",
    "AccountId": "string",
    "CreationDate": "string",
    "Description": "string",
    "PermissionsToCreateVolume": {
      "AccountIds": [
        "string"
      ],
      "GlobalPermission": true
    },
    "Progress": 0,
    "SnapshotId": "string",
    "State": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ],
    "VolumeId": "string",
    "VolumeSize": 0
  }
}

CreateSnapshotExportTask

POST /CreateSnapshotExportTask

Exports a snapshot to an OUTSCALE Object Storage (OOS) bucket.
This action enables you to create a backup of your snapshot or to copy it to another account. You, or other users you send a pre-signed URL to, can then download this snapshot from the bucket using the CreateSnapshot method.
This procedure enables you to copy a snapshot between accounts within the same Region or in different Regions. To copy a snapshot within the same Region, you can also use the CreateSnapshot direct method. The copy of the source snapshot is independent and belongs to you.

Code samples

osc-cli api CreateSnapshotExportTask PROFILE \
  --DryRun False \
  --OsuExport '{ \
      "DiskImageFormat": "string", \
      "OsuApiKey": { \
        "ApiKeyId": "string", \
        "SecretKey": "string" \
      }, \
      "OsuBucket": "string", \
      "OsuManifestUrl": "string", \
      "OsuPrefix": "string" \
    }' \
  --SnapshotId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateSnapshotExportTask \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "OsuExport": { \
    "DiskImageFormat": "string", \
    "OsuApiKey": { \
      "ApiKeyId": "string", \
      "SecretKey": "string" \
    }, \
    "OsuBucket": "string", \
    "OsuManifestUrl": "string", \
    "OsuPrefix": "string" \
  }, \
  "SnapshotId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "OsuExport": { 
    "DiskImageFormat": "string", 
    "OsuApiKey": { 
      "ApiKeyId": "string", 
      "SecretKey": "string" 
    }, 
    "OsuBucket": "string", 
    "OsuManifestUrl": "string", 
    "OsuPrefix": "string" 
  },
  "SnapshotId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateSnapshotExportTask', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
OsuExport OsuExportToCreate true Information about the OOS export task to create.
» DiskImageFormat string true The format of the export disk (qcow2 | raw).
» OsuApiKey OsuApiKey false Information about the OOS API key.
»» ApiKeyId string false The API key of the OOS account that enables you to access the bucket.
»» SecretKey string false The secret key of the OOS account that enables you to access the bucket.
» OsuBucket string true The name of the OOS bucket where you want to export the object.
» OsuManifestUrl string false The URL of the manifest file.
» OsuPrefix string false The prefix for the key of the OOS object.
SnapshotId string true The ID of the snapshot to export.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateSnapshotExportTaskResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "SnapshotExportTask": {
    "Comment": "string",
    "OsuExport": {
      "DiskImageFormat": "string",
      "OsuBucket": "string",
      "OsuPrefix": "string"
    },
    "Progress": 0,
    "SnapshotId": "string",
    "State": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ],
    "TaskId": "string"
  }
}

DeleteSnapshot

POST /DeleteSnapshot

Deletes a specified snapshot.
You cannot delete a snapshot that is currently used by an OUTSCALE machine image (OMI). To do so, you first need to delete the corresponding OMI. For more information, see the DeleteImage method.

Code samples

osc-cli api DeleteSnapshot PROFILE \
  --DryRun False \
  --SnapshotId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteSnapshot \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "SnapshotId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "SnapshotId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteSnapshot', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
SnapshotId string true The ID of the snapshot you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteSnapshotResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadSnapshotExportTasks

POST /ReadSnapshotExportTasks

Lists one or more snapshot export tasks.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadSnapshotExportTasks PROFILE \
  --DryRun False \
  --Filters '{ \
      "TaskIds": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadSnapshotExportTasks \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "TaskIds": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "TaskIds": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadSnapshotExportTasks', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersExportTask false One or more filters.
» TaskIds [string] false The IDs of the export tasks.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadSnapshotExportTasksResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "SnapshotExportTasks": [
    {
      "Comment": "string",
      "OsuExport": {
        "DiskImageFormat": "string",
        "OsuBucket": "string",
        "OsuPrefix": "string"
      },
      "Progress": 0,
      "SnapshotId": "string",
      "State": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ],
      "TaskId": "string"
    }
  ]
}

ReadSnapshots

POST /ReadSnapshots

Lists one or more snapshots that are available to you and the permissions to create volumes from them.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadSnapshots PROFILE \
  --DryRun False \
  --Filters '{ \
      "AccountAliases": ["string"], \
      "AccountIds": ["string"], \
      "Descriptions": ["string"], \
      "PermissionsToCreateVolumeAccountIds": ["string"], \
      "PermissionsToCreateVolumeGlobalPermission": True, \
      "Progresses": [0], \
      "SnapshotIds": ["string"], \
      "States": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"], \
      "VolumeIds": ["string"], \
      "VolumeSizes": [0] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadSnapshots \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "AccountAliases": [ \
      "string" \
    ], \
    "AccountIds": [ \
      "string" \
    ], \
    "Descriptions": [ \
      "string" \
    ], \
    "PermissionsToCreateVolumeAccountIds": [ \
      "string" \
    ], \
    "PermissionsToCreateVolumeGlobalPermission": true, \
    "Progresses": [ \
      0 \
    ], \
    "SnapshotIds": [ \
      "string" \
    ], \
    "States": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ], \
    "VolumeIds": [ \
      "string" \
    ], \
    "VolumeSizes": [ \
      0 \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "AccountAliases": ["string"], 
    "AccountIds": ["string"], 
    "Descriptions": ["string"], 
    "PermissionsToCreateVolumeAccountIds": ["string"], 
    "PermissionsToCreateVolumeGlobalPermission": True, 
    "Progresses": [0], 
    "SnapshotIds": ["string"], 
    "States": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"], 
    "VolumeIds": ["string"], 
    "VolumeSizes": [0] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadSnapshots', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersSnapshot false One or more filters.
» AccountAliases [string] false The account aliases of the owners of the snapshots.
» AccountIds [string] false The account IDs of the owners of the snapshots.
» Descriptions [string] false The descriptions of the snapshots.
» PermissionsToCreateVolumeAccountIds [string] false The account IDs of one or more users who have permissions to create volumes.
» PermissionsToCreateVolumeGlobalPermission boolean false If true, lists all public volumes. If false, lists all private volumes.
» Progresses [integer] false The progresses of the snapshots, as a percentage.
» SnapshotIds [string] false The IDs of the snapshots.
» States [string] false The states of the snapshots (in-queue | completed | error).
» TagKeys [string] false The keys of the tags associated with the snapshots.
» TagValues [string] false The values of the tags associated with the snapshots.
» Tags [string] false The key/value combination of the tags associated with the snapshots, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.
» VolumeIds [string] false The IDs of the volumes used to create the snapshots.
» VolumeSizes [integer] false The sizes of the volumes used to create the snapshots, in gibibytes (GiB).

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadSnapshotsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Snapshots": [
    {
      "AccountAlias": "string",
      "AccountId": "string",
      "CreationDate": "string",
      "Description": "string",
      "PermissionsToCreateVolume": {
        "AccountIds": [
          "string"
        ],
        "GlobalPermission": true
      },
      "Progress": 0,
      "SnapshotId": "string",
      "State": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ],
      "VolumeId": "string",
      "VolumeSize": 0
    }
  ]
}

UpdateSnapshot

POST /UpdateSnapshot

Modifies the permissions for a specified snapshot.
You can add or remove permissions for specified account IDs or groups. You can share a snapshot with a user that is in the same Region. The user can create a copy of the snapshot you shared, obtaining all the rights for the copy of the snapshot.

Code samples

osc-cli api UpdateSnapshot PROFILE \
  --DryRun False \
  --PermissionsToCreateVolume '{ \
      "Additions": { \
        "AccountIds": ["string"], \
        "GlobalPermission": True \
      }, \
      "Removals": { \
        "AccountIds": ["string"], \
        "GlobalPermission": True \
      } \
    }' \
  --SnapshotId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateSnapshot \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "PermissionsToCreateVolume": { \
    "Additions": { \
      "AccountIds": [ \
        "string" \
      ], \
      "GlobalPermission": true \
    }, \
    "Removals": { \
      "AccountIds": [ \
        "string" \
      ], \
      "GlobalPermission": true \
    } \
  }, \
  "SnapshotId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "PermissionsToCreateVolume": { 
    "Additions": { 
      "AccountIds": ["string"], 
      "GlobalPermission": True 
    }, 
    "Removals": { 
      "AccountIds": ["string"], 
      "GlobalPermission": True 
    } 
  },
  "SnapshotId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateSnapshot', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
PermissionsToCreateVolume PermissionsOnResourceCreation true Information about the permissions for the resource.
» Additions PermissionsOnResource false Information about the users who have permissions for the resource.
»» AccountIds [string] false The account ID of one or more users who have permissions for the resource.
»» GlobalPermission boolean false If true, the resource is public. If false, the resource is private.
» Removals PermissionsOnResource false Information about the users who have permissions for the resource.
SnapshotId string true The ID of the snapshot.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateSnapshotResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Snapshot": {
    "AccountAlias": "string",
    "AccountId": "string",
    "CreationDate": "string",
    "Description": "string",
    "PermissionsToCreateVolume": {
      "AccountIds": [
        "string"
      ],
      "GlobalPermission": true
    },
    "Progress": 0,
    "SnapshotId": "string",
    "State": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ],
    "VolumeId": "string",
    "VolumeSize": 0
  }
}

Subnet

CreateSubnet

POST /CreateSubnet

Creates a Subnet in an existing Net.
To create a Subnet in a Net, you have to provide the ID of the Net and the IP range for the Subnet (its network range). Once the Subnet is created, you cannot modify its IP range.
The IP range of the Subnet can be either the same as the Net one if you create only a single Subnet in this Net, or a subset of the Net one. In case of several Subnets in a Net, their IP ranges must not overlap. The smallest Subnet you can create uses a /30 netmask (four IPs).

Code samples

osc-cli api CreateSubnet PROFILE \
  --DryRun False \
  --IpRange "string" \
  --NetId "string" \
  --SubregionName "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateSubnet \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "IpRange": "string", \
  "NetId": "string", \
  "SubregionName": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "IpRange": "string",
  "NetId": "string",
  "SubregionName": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateSubnet', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
IpRange string true The IP range in the Subnet, in CIDR notation (for example, 10.0.0.0/16).
NetId string true The ID of the Net for which you want to create a Subnet.
SubregionName string false The name of the Subregion in which you want to create the Subnet.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateSubnetResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
409 Conflict The HTTP 409 response (Conflict). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Subnet": {
    "AvailableIpsCount": 0,
    "IpRange": "string",
    "MapPublicIpOnLaunch": true,
    "NetId": "string",
    "State": "string",
    "SubnetId": "string",
    "SubregionName": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  }
}

DeleteSubnet

POST /DeleteSubnet

Deletes a specified Subnet.
Before deleting the Subnet, you need to delete all resources associated with the Subnet:

Code samples

osc-cli api DeleteSubnet PROFILE \
  --DryRun False \
  --SubnetId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteSubnet \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "SubnetId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "SubnetId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteSubnet', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
SubnetId string true The ID of the Subnet you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteSubnetResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadSubnets

POST /ReadSubnets

Lists one or more of your Subnets.
If you do not specify any Subnet ID, this action describes all of your Subnets.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadSubnets PROFILE \
  --DryRun False \
  --Filters '{ \
      "AvailableIpsCounts": [0], \
      "IpRanges": ["string"], \
      "NetIds": ["string"], \
      "States": ["string"], \
      "SubnetIds": ["string"], \
      "SubregionNames": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadSubnets \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "AvailableIpsCounts": [ \
      0 \
    ], \
    "IpRanges": [ \
      "string" \
    ], \
    "NetIds": [ \
      "string" \
    ], \
    "States": [ \
      "string" \
    ], \
    "SubnetIds": [ \
      "string" \
    ], \
    "SubregionNames": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "AvailableIpsCounts": [0], 
    "IpRanges": ["string"], 
    "NetIds": ["string"], 
    "States": ["string"], 
    "SubnetIds": ["string"], 
    "SubregionNames": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadSubnets', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersSubnet false One or more filters.
» AvailableIpsCounts [integer] false The number of available IPs.
» IpRanges [string] false The IP ranges in the Subnets, in CIDR notation (for example, 10.0.0.0/16).
» NetIds [string] false The IDs of the Nets in which the Subnets are.
» States [string] false The states of the Subnets (pending | available).
» SubnetIds [string] false The IDs of the Subnets.
» SubregionNames [string] false The names of the Subregions in which the Subnets are located.
» TagKeys [string] false The keys of the tags associated with the Subnets.
» TagValues [string] false The values of the tags associated with the Subnets.
» Tags [string] false The key/value combination of the tags associated with the Subnets, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadSubnetsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Subnets": [
    {
      "AvailableIpsCount": 0,
      "IpRange": "string",
      "MapPublicIpOnLaunch": true,
      "NetId": "string",
      "State": "string",
      "SubnetId": "string",
      "SubregionName": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ]
    }
  ]
}

UpdateSubnet

POST /UpdateSubnet

Modifies the specified attribute of a Subnet.

Code samples

osc-cli api UpdateSubnet PROFILE \
  --DryRun False \
  --MapPublicIpOnLaunch True \
  --SubnetId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateSubnet \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "MapPublicIpOnLaunch": true, \
  "SubnetId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "MapPublicIpOnLaunch": True,
  "SubnetId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateSubnet', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
MapPublicIpOnLaunch boolean true If true, a public IP is assigned to the network interface cards (NICs) created in the specified Subnet.
SubnetId string true The ID of the Subnet.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateSubnetResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Subnet": {
    "AvailableIpsCount": 0,
    "IpRange": "string",
    "MapPublicIpOnLaunch": true,
    "NetId": "string",
    "State": "string",
    "SubnetId": "string",
    "SubregionName": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  }
}

Subregion

ReadSubregions

POST /ReadSubregions

Lists one or more of the enabled Subregions that you can access in the current Region.

[NOTE]

Code samples

osc-cli api ReadSubregions PROFILE \
  --DryRun False \
  --Filters '{ \
      "SubregionNames": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadSubregions \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "SubregionNames": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "SubregionNames": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadSubregions', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersSubregion false One or more filters.
» SubregionNames [string] false The names of the Subregions.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadSubregionsResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Subregions": [
    {
      "RegionName": "string",
      "State": "string",
      "SubregionName": "string"
    }
  ]
}

Tag

CreateTags

POST /CreateTags

Adds one or more tags to the specified resources.
If a tag with the same key already exists for the resource, the tag value is replaced.
You can tag the following resources using their IDs:

Code samples

osc-cli api CreateTags PROFILE \
  --DryRun False \
  --ResourceIds '["string"]' \
  --Tags '[ \
      { \
        "Key": "string", \
        "Value": "string" \
      } \
    ]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateTags \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "ResourceIds": [ \
    "string" \
  ], \
  "Tags": [ \
    { \
      "Key": "string", \
      "Value": "string" \
    } \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "ResourceIds": ["string"],
  "Tags": [ 
    { 
      "Key": "string", 
      "Value": "string" 
    } 
  ]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateTags', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
ResourceIds [string] true One or more resource IDs.
Tags [ResourceTag] true One or more tags to add to the specified resources.
» Key string true The key of the tag, with a minimum of 1 character.
» Value string true The value of the tag, between 0 and 255 characters.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateTagsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

DeleteTags

POST /DeleteTags

Deletes one or more tags from the specified resources.

Code samples

osc-cli api DeleteTags PROFILE \
  --DryRun False \
  --ResourceIds '["string"]' \
  --Tags '[ \
      { \
        "Key": "string", \
        "Value": "string" \
      } \
    ]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteTags \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "ResourceIds": [ \
    "string" \
  ], \
  "Tags": [ \
    { \
      "Key": "string", \
      "Value": "string" \
    } \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "ResourceIds": ["string"],
  "Tags": [ 
    { 
      "Key": "string", 
      "Value": "string" 
    } 
  ]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteTags', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
ResourceIds [string] true One or more resource IDs.
Tags [ResourceTag] true One or more tags to delete (if you set a tag value, only the tags matching exactly this value are deleted).
» Key string true The key of the tag, with a minimum of 1 character.
» Value string true The value of the tag, between 0 and 255 characters.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteTagsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadTags

POST /ReadTags

Lists one or more tags for your resources.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadTags PROFILE \
  --DryRun False \
  --Filters '{ \
      "Keys": ["string"], \
      "ResourceIds": ["string"], \
      "ResourceTypes": ["string"], \
      "Values": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadTags \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "Keys": [ \
      "string" \
    ], \
    "ResourceIds": [ \
      "string" \
    ], \
    "ResourceTypes": [ \
      "string" \
    ], \
    "Values": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "Keys": ["string"], 
    "ResourceIds": ["string"], 
    "ResourceTypes": ["string"], 
    "Values": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadTags', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersTag false One or more filters.
» Keys [string] false The keys of the tags that are assigned to the resources. You can use this filter alongside the Values filter. In that case, you filter the resources corresponding to each tag, regardless of the other filter.
» ResourceIds [string] false The IDs of the resources with which the tags are associated.
» ResourceTypes [string] false The resource type (vm | image | volume | snapshot | public-ip | security-group | route-table | nic | net | subnet | net-peering | net-access-point | nat-service | internet-service | client-gateway | virtual-gateway | vpn-connection | dhcp-options | task).
» Values [string] false The values of the tags that are assigned to the resources. You can use this filter alongside the TagKeys filter. In that case, you filter the resources corresponding to each tag, regardless of the other filter.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadTagsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Tags": [
    {
      "Key": "string",
      "ResourceId": "string",
      "ResourceType": "string",
      "Value": "string"
    }
  ]
}

Task

DeleteExportTask

POST /DeleteExportTask

Deletes an export task.
If the export task is not running, the command fails and an error is returned.

Code samples

osc-cli api DeleteExportTask PROFILE \
  --DryRun False \
  --ExportTaskId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteExportTask \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "ExportTaskId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "ExportTaskId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteExportTask', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
ExportTaskId string true The ID of the export task to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteExportTaskResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

VirtualGateway

CreateVirtualGateway

POST /CreateVirtualGateway

Creates a virtual gateway.
A virtual gateway is the access point on the Net side of a VPN connection.

Code samples

osc-cli api CreateVirtualGateway PROFILE \
  --ConnectionType "string" \
  --DryRun False 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateVirtualGateway \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "ConnectionType": "string", \
  "DryRun": true \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "ConnectionType": "string",
  "DryRun": False
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateVirtualGateway', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
ConnectionType string true The type of VPN connection supported by the virtual gateway (only ipsec.1 is supported).
DryRun boolean false If true, checks whether you have the required permissions to perform the action.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateVirtualGatewayResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "VirtualGateway": {
    "ConnectionType": "string",
    "NetToVirtualGatewayLinks": [
      {
        "NetId": "string",
        "State": "string"
      }
    ],
    "State": "string",
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ],
    "VirtualGatewayId": "string"
  }
}

DeleteVirtualGateway

POST /DeleteVirtualGateway

Deletes a specified virtual gateway.
Before deleting a virtual gateway, we recommend to detach it from the Net and delete the VPN connection.

Code samples

osc-cli api DeleteVirtualGateway PROFILE \
  --DryRun False \
  --VirtualGatewayId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteVirtualGateway \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "VirtualGatewayId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "VirtualGatewayId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteVirtualGateway', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
VirtualGatewayId string true The ID of the virtual gateway you want to delete.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteVirtualGatewayResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

LinkVirtualGateway

POST /LinkVirtualGateway

Attaches a virtual gateway to a Net.

Code samples

osc-cli api LinkVirtualGateway PROFILE \
  --DryRun False \
  --NetId "string" \
  --VirtualGatewayId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/LinkVirtualGateway \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "NetId": "string", \
  "VirtualGatewayId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "NetId": "string",
  "VirtualGatewayId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/LinkVirtualGateway', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NetId string true The ID of the Net to which you want to attach the virtual gateway.
VirtualGatewayId string true The ID of the virtual gateway.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). LinkVirtualGatewayResponse

Example responses

200 Response

{
  "NetToVirtualGatewayLink": {
    "NetId": "string",
    "State": "string"
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

ReadVirtualGateways

POST /ReadVirtualGateways

Lists one or more virtual gateways.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadVirtualGateways PROFILE \
  --DryRun False \
  --Filters '{ \
      "ConnectionTypes": ["string"], \
      "LinkNetIds": ["string"], \
      "LinkStates": ["string"], \
      "States": ["string"], \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"], \
      "VirtualGatewayIds": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadVirtualGateways \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "ConnectionTypes": [ \
      "string" \
    ], \
    "LinkNetIds": [ \
      "string" \
    ], \
    "LinkStates": [ \
      "string" \
    ], \
    "States": [ \
      "string" \
    ], \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ], \
    "VirtualGatewayIds": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "ConnectionTypes": ["string"], 
    "LinkNetIds": ["string"], 
    "LinkStates": ["string"], 
    "States": ["string"], 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"], 
    "VirtualGatewayIds": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadVirtualGateways', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersVirtualGateway false One or more filters.
» ConnectionTypes [string] false The types of the virtual gateways (only ipsec.1 is supported).
» LinkNetIds [string] false The IDs of the Nets the virtual gateways are attached to.
» LinkStates [string] false The current states of the attachments between the virtual gateways and the Nets (attaching | attached | detaching | detached).
» States [string] false The states of the virtual gateways (pending | available | deleting | deleted).
» TagKeys [string] false The keys of the tags associated with the virtual gateways.
» TagValues [string] false The values of the tags associated with the virtual gateways.
» Tags [string] false The key/value combination of the tags associated with the virtual gateways, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.
» VirtualGatewayIds [string] false The IDs of the virtual gateways.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadVirtualGatewaysResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "VirtualGateways": [
    {
      "ConnectionType": "string",
      "NetToVirtualGatewayLinks": [
        {
          "NetId": "string",
          "State": "string"
        }
      ],
      "State": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ],
      "VirtualGatewayId": "string"
    }
  ]
}

UnlinkVirtualGateway

POST /UnlinkVirtualGateway

Detaches a virtual gateway from a Net.
You must wait until the virtual gateway is in the detached state before you can attach another Net to it or delete the Net it was previously attached to.

Code samples

osc-cli api UnlinkVirtualGateway PROFILE \
  --DryRun False \
  --NetId "string" \
  --VirtualGatewayId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UnlinkVirtualGateway \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "NetId": "string", \
  "VirtualGatewayId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "NetId": "string",
  "VirtualGatewayId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UnlinkVirtualGateway', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
NetId string true The ID of the Net from which you want to detach the virtual gateway.
VirtualGatewayId string true The ID of the virtual gateway.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UnlinkVirtualGatewayResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

UpdateRoutePropagation

POST /UpdateRoutePropagation

Configures the propagation of routes to a specified route table of a Net by a virtual gateway.

Code samples

osc-cli api UpdateRoutePropagation PROFILE \
  --DryRun False \
  --Enable True \
  --RouteTableId "string" \
  --VirtualGatewayId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateRoutePropagation \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Enable": true, \
  "RouteTableId": "string", \
  "VirtualGatewayId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Enable": True,
  "RouteTableId": "string",
  "VirtualGatewayId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateRoutePropagation', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Enable boolean true If true, a virtual gateway can propagate routes to a specified route table of a Net. If false, the propagation is disabled.
RouteTableId string true The ID of the route table.
VirtualGatewayId string true The ID of the virtual gateway.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). UpdateRoutePropagationResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "RouteTable": {
    "LinkRouteTables": [
      {
        "LinkRouteTableId": "string",
        "Main": true,
        "RouteTableId": "string",
        "SubnetId": "string"
      }
    ],
    "NetId": "string",
    "RoutePropagatingVirtualGateways": [
      {
        "VirtualGatewayId": "string"
      }
    ],
    "RouteTableId": "string",
    "Routes": [
      {
        "CreationMethod": "string",
        "DestinationIpRange": "string",
        "DestinationServiceId": "string",
        "GatewayId": "string",
        "NatServiceId": "string",
        "NetAccessPointId": "string",
        "NetPeeringId": "string",
        "NicId": "string",
        "State": "string",
        "VmAccountId": "string",
        "VmId": "string"
      }
    ],
    "Tags": [
      {
        "Key": "string",
        "Value": "string"
      }
    ]
  }
}

Vm

CreateVms

POST /CreateVms

Creates new virtual machines (VMs), and then launches them.
This action enables you to create a specified number of VMs using an OUTSCALE machine image (OMI) that you are allowed to use, and then to automatically launch them.
The VMs remain in the pending state until they are created and ready to be used. Once automatically launched, they are in the running state.
To check the state of your VMs, call the ReadVms method.
If not specified, the security group used by the service is the default one.
The metadata server enables you to get the public key provided when the VM is launched. Official OMIs contain a script to get this public key and put it inside the VM to provide secure access without password.

Code samples

osc-cli api CreateVms PROFILE \
  --BlockDeviceMappings '[ \
      { \
        "Bsu": {"DeleteOnVmDeletion": True, "Iops": 0, "SnapshotId": "string", "VolumeSize": 0, "VolumeType": "string"}, \
        "DeviceName": "string", \
        "NoDevice": "string", \
        "VirtualDeviceName": "string" \
      } \
    ]' \
  --BootOnCreation True \
  --BsuOptimized True \
  --ClientToken "string" \
  --DeletionProtection True \
  --DryRun False \
  --ImageId "string" \
  --KeypairName "string" \
  --MaxVmsCount 0 \
  --MinVmsCount 0 \
  --Nics '[ \
      { \
        "DeleteOnVmDeletion": True, \
        "Description": "string", \
        "DeviceNumber": 0, \
        "NicId": "string", \
        "PrivateIps": [{"IsPrimary": True, "PrivateIp": "string"}], \
        "SecondaryPrivateIpCount": 0, \
        "SecurityGroupIds": ["string"], \
        "SubnetId": "string" \
      } \
    ]' \
  --Performance "medium" \
  --Placement '{ \
      "SubregionName": "string", \
      "Tenancy": "string" \
    }' \
  --PrivateIps '["string"]' \
  --SecurityGroupIds '["string"]' \
  --SecurityGroups '["string"]' \
  --SubnetId "string" \
  --UserData "string" \
  --VmInitiatedShutdownBehavior "string" \
  --VmType "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/CreateVms \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "BlockDeviceMappings": [ \
    { \
      "Bsu": { \
        "DeleteOnVmDeletion": true, \
        "Iops": 0, \
        "SnapshotId": "string", \
        "VolumeSize": 0, \
        "VolumeType": "string" \
      }, \
      "DeviceName": "string", \
      "NoDevice": "string", \
      "VirtualDeviceName": "string" \
    } \
  ], \
  "BootOnCreation": true, \
  "BsuOptimized": true, \
  "ClientToken": "string", \
  "DeletionProtection": true, \
  "DryRun": true, \
  "ImageId": "string", \
  "KeypairName": "string", \
  "MaxVmsCount": 0, \
  "MinVmsCount": 0, \
  "Nics": [ \
    { \
      "DeleteOnVmDeletion": true, \
      "Description": "string", \
      "DeviceNumber": 0, \
      "NicId": "string", \
      "PrivateIps": [ \
        { \
          "IsPrimary": true, \
          "PrivateIp": "string" \
        } \
      ], \
      "SecondaryPrivateIpCount": 0, \
      "SecurityGroupIds": [ \
        "string" \
      ], \
      "SubnetId": "string" \
    } \
  ], \
  "Performance": "medium", \
  "Placement": { \
    "SubregionName": "string", \
    "Tenancy": "string" \
  }, \
  "PrivateIps": [ \
    "string" \
  ], \
  "SecurityGroupIds": [ \
    "string" \
  ], \
  "SecurityGroups": [ \
    "string" \
  ], \
  "SubnetId": "string", \
  "UserData": "string", \
  "VmInitiatedShutdownBehavior": "string", \
  "VmType": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "BlockDeviceMappings": [ 
    { 
      "Bsu": { 
        "DeleteOnVmDeletion": True, 
        "Iops": 0, 
        "SnapshotId": "string", 
        "VolumeSize": 0, 
        "VolumeType": "string" 
      }, 
      "DeviceName": "string", 
      "NoDevice": "string", 
      "VirtualDeviceName": "string" 
    } 
  ],
  "BootOnCreation": True,
  "BsuOptimized": True,
  "ClientToken": "string",
  "DeletionProtection": True,
  "DryRun": False,
  "ImageId": "string",
  "KeypairName": "string",
  "MaxVmsCount": 0,
  "MinVmsCount": 0,
  "Nics": [ 
    { 
      "DeleteOnVmDeletion": True, 
      "Description": "string", 
      "DeviceNumber": 0, 
      "NicId": "string", 
      "PrivateIps": [ 
        {"IsPrimary": True, "PrivateIp": "string"} 
      ], 
      "SecondaryPrivateIpCount": 0, 
      "SecurityGroupIds": ["string"], 
      "SubnetId": "string" 
    } 
  ],
  "Performance": "medium",
  "Placement": { 
    "SubregionName": "string", 
    "Tenancy": "string" 
  },
  "PrivateIps": ["string"],
  "SecurityGroupIds": ["string"],
  "SecurityGroups": ["string"],
  "SubnetId": "string",
  "UserData": "string",
  "VmInitiatedShutdownBehavior": "string",
  "VmType": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/CreateVms', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
BlockDeviceMappings [BlockDeviceMappingVmCreation] false One or more block device mappings.
» Bsu BsuToCreate false Information about the BSU volume to create.
»» DeleteOnVmDeletion boolean false By default or if set to true, the volume is deleted when terminating the VM. If false, the volume is not deleted when terminating the VM.
»» Iops integer false The number of I/O operations per second (IOPS). This parameter must be specified only if you create an io1 volume. The maximum number of IOPS allowed for io1 volumes is 13000.
»» SnapshotId string false The ID of the snapshot used to create the volume.
»» VolumeSize integer false The size of the volume, in gibibytes (GiB).
»» VolumeType string false The type of the volume (standard | io1 | gp2). If not specified in the request, a standard volume is created.
» DeviceName string false The name of the device.
» NoDevice string false Removes the device which is included in the block device mapping of the OMI.
» VirtualDeviceName string false The name of the virtual device (ephemeralN).
BootOnCreation boolean false By default or if true, the VM is started on creation. If false, the VM is stopped on creation.
BsuOptimized boolean false If true, the VM is created with optimized BSU I/O.
ClientToken string false A unique identifier which enables you to manage the idempotency.
DeletionProtection boolean false If true, you cannot terminate the VM using Cockpit, the CLI or the API. If false, you can.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
ImageId string true The ID of the OMI used to create the VM. You can find the list of OMIs by calling the ReadImages method.
KeypairName string false The name of the keypair.
MaxVmsCount integer false The maximum number of VMs you want to create. If all the VMs cannot be created, the largest possible number of VMs above MinVmsCount is created.
MinVmsCount integer false The minimum number of VMs you want to create. If this number of VMs cannot be created, no VMs are created.
Nics [NicForVmCreation] false One or more NICs. If you specify this parameter, you must define one NIC as the primary network interface of the VM with 0 as its device number.
» DeleteOnVmDeletion boolean false By default or if set to true, the NIC is deleted when the VM is terminated. You can specify this parameter only for a new NIC. To modify this value for an existing NIC, see UpdateNic.
» Description string false The description of the NIC, if you are creating a NIC when creating the VM.
» DeviceNumber integer false The index of the VM device for the NIC attachment (between 0 and 7, both included). This parameter is required if you create a NIC when creating the VM.
» NicId string false The ID of the NIC, if you are attaching an existing NIC when creating a VM.
» PrivateIps [PrivateIpLight] false One or more private IPs to assign to the NIC, if you create a NIC when creating a VM. Only one private IP can be the primary private IP.
»» IsPrimary boolean false If true, the IP is the primary private IP of the NIC.
»» PrivateIp string false The private IP of the NIC.
» SecondaryPrivateIpCount integer false The number of secondary private IPs, if you create a NIC when creating a VM. This parameter cannot be specified if you specified more than one private IP in the PrivateIps parameter.
» SecurityGroupIds [string] false One or more IDs of security groups for the NIC, if you acreate a NIC when creating a VM.
» SubnetId string false The ID of the Subnet for the NIC, if you create a NIC when creating a VM.
Performance string false The performance of the VM (medium | high | highest).
Placement Placement false Information about the placement of the VM.
» SubregionName string false The name of the Subregion.
» Tenancy string false The tenancy of the VM (default | dedicated).
PrivateIps [string] false One or more private IPs of the VM.
SecurityGroupIds [string] false One or more IDs of security group for the VMs.
SecurityGroups [string] false One or more names of security groups for the VMs.
SubnetId string false The ID of the Subnet in which you want to create the VM.
UserData string false Data or script used to add a specific configuration to the VM. It must be Base64-encoded and is limited to 500 kibibytes (KiB).
VmInitiatedShutdownBehavior string false The VM behavior when you stop it. By default or if set to stop, the VM stops. If set to restart, the VM stops then automatically restarts. If set to terminate, the VM stops and is terminated.
VmType string false The type of VM (t2.small by default).

Detailed descriptions

»» VolumeSize: The size of the volume, in gibibytes (GiB).
If you specify a snapshot ID, the volume size must be at least equal to the snapshot size.
If you specify a snapshot ID but no volume size, the volume is created with a size similar to the snapshot one.

»» VolumeType: The type of the volume (standard | io1 | gp2). If not specified in the request, a standard volume is created.
For more information about volume types, see Volume Types and IOPS.

VmType: The type of VM (t2.small by default).
For more information, see Instance Types.

Enumerated Values

Parameter Value
Performance medium
Performance high
Performance highest

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). CreateVmsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Vms": [
    {
      "Architecture": "string",
      "BlockDeviceMappings": [
        {
          "Bsu": {
            "DeleteOnVmDeletion": true,
            "LinkDate": "2019-08-24",
            "State": "string",
            "VolumeId": "string"
          },
          "DeviceName": "string"
        }
      ],
      "BsuOptimized": true,
      "ClientToken": "string",
      "CreationDate": "string",
      "DeletionProtection": true,
      "Hypervisor": "string",
      "ImageId": "string",
      "IsSourceDestChecked": true,
      "KeypairName": "string",
      "LaunchNumber": 0,
      "NetId": "string",
      "Nics": [
        {
          "AccountId": "string",
          "Description": "string",
          "IsSourceDestChecked": true,
          "LinkNic": {
            "DeleteOnVmDeletion": true,
            "DeviceNumber": 0,
            "LinkNicId": "string",
            "State": "string"
          },
          "LinkPublicIp": {
            "PublicDnsName": "string",
            "PublicIp": "string",
            "PublicIpAccountId": "string"
          },
          "MacAddress": "string",
          "NetId": "string",
          "NicId": "string",
          "PrivateDnsName": "string",
          "PrivateIps": [
            {
              "IsPrimary": true,
              "LinkPublicIp": {
                "PublicDnsName": "string",
                "PublicIp": "string",
                "PublicIpAccountId": "string"
              },
              "PrivateDnsName": "string",
              "PrivateIp": "string"
            }
          ],
          "SecurityGroups": [
            {
              "SecurityGroupId": "string",
              "SecurityGroupName": "string"
            }
          ],
          "State": "string",
          "SubnetId": "string"
        }
      ],
      "OsFamily": "string",
      "Performance": "string",
      "Placement": {
        "SubregionName": "string",
        "Tenancy": "string"
      },
      "PrivateDnsName": "string",
      "PrivateIp": "string",
      "ProductCodes": [
        "string"
      ],
      "PublicDnsName": "string",
      "PublicIp": "string",
      "ReservationId": "string",
      "RootDeviceName": "string",
      "RootDeviceType": "string",
      "SecurityGroups": [
        {
          "SecurityGroupId": "string",
          "SecurityGroupName": "string"
        }
      ],
      "State": "string",
      "StateReason": "string",
      "SubnetId": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ],
      "UserData": "string",
      "VmId": "string",
      "VmInitiatedShutdownBehavior": "string",
      "VmType": "string"
    }
  ]
}

DeleteVms

POST /DeleteVms

Performs a shut down for at least one virtual machine (VM).
This operation is idempotent, that means that all calls succeed if you terminate a VM more than once.

Code samples

osc-cli api DeleteVms PROFILE \
  --DryRun False \
  --VmIds '["string"]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/DeleteVms \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "VmIds": [ \
    "string" \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "VmIds": ["string"]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/DeleteVms', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
VmIds [string] true One or more IDs of VMs.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). DeleteVmsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Vms": [
    {
      "CurrentState": "string",
      "PreviousState": "string",
      "VmId": "string"
    }
  ]
}

ReadAdminPassword

POST /ReadAdminPassword

Gets the administrator password for a Windows running virtual machine (VM).
The administrator password is encrypted using the keypair you specified when launching the VM.

[NOTE]
The administrator password is generated only on the first boot of the Windows VM. It is not returned after the first boot.

Code samples

osc-cli api ReadAdminPassword PROFILE \
  --DryRun False \
  --VmId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadAdminPassword \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "VmId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "VmId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadAdminPassword', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
VmId string true The ID of the VM.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadAdminPasswordResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "AdminPassword": "string",
  "ResponseContext": {
    "RequestId": "string"
  },
  "VmId": "string"
}

ReadConsoleOutput

POST /ReadConsoleOutput

Gets the console output for a virtual machine (VM). This console provides the most recent 64 KiB output.

[NOTE]
On Windows VMs, the console is handled only on the first boot. It returns no output after the first boot.

Code samples

osc-cli api ReadConsoleOutput PROFILE \
  --DryRun False \
  --VmId "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadConsoleOutput \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "VmId": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "VmId": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadConsoleOutput', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
VmId string true The ID of the VM.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadConsoleOutputResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ConsoleOutput": "string",
  "ResponseContext": {
    "RequestId": "string"
  },
  "VmId": "string"
}

ReadVmTypes

POST /ReadVmTypes

Lists one or more predefined VM types.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadVmTypes PROFILE \
  --DryRun False \
  --Filters '{ \
      "BsuOptimized": True, \
      "MemorySizes": [0], \
      "VcoreCounts": [0], \
      "VmTypeNames": ["string"], \
      "VolumeCounts": [0], \
      "VolumeSizes": [0] \
    }' 

curl -X POST https://api.{region}.outscale.com/api/v1/ReadVmTypes \
  -H 'Content-Type: application/json' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "BsuOptimized": true, \
    "MemorySizes": [ \
      0 \
    ], \
    "VcoreCounts": [ \
      0 \
    ], \
    "VmTypeNames": [ \
      "string" \
    ], \
    "VolumeCounts": [ \
      0 \
    ], \
    "VolumeSizes": [ \
      0 \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "BsuOptimized": True, 
    "MemorySizes": [0], 
    "VcoreCounts": [0], 
    "VmTypeNames": ["string"], 
    "VolumeCounts": [0], 
    "VolumeSizes": [0] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadVmTypes', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersVmType false One or more filters.
» BsuOptimized boolean false Indicates whether the VM is optimized for BSU I/O.
» MemorySizes [number] false The amounts of memory, in gibibytes (GiB).
» VcoreCounts [integer] false The numbers of vCores.
» VmTypeNames [string] false The names of the VM types. For more information, see Instance Types.
» VolumeCounts [integer] false The maximum number of ephemeral storage disks.
» VolumeSizes [integer] false The size of one ephemeral storage disk, in gibibytes (GiB).

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadVmTypesResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "VmTypes": [
    {
      "BsuOptimized": true,
      "MaxPrivateIps": 0,
      "MemorySize": 0,
      "VcoreCount": 0,
      "VmTypeName": "string",
      "VolumeCount": 0,
      "VolumeSize": 0
    }
  ]
}

ReadVms

POST /ReadVms

Lists one or more of your virtual machines (VMs).
If you provide one or more VM IDs, this action returns a description for all of these VMs. If you do not provide any VM ID, this action returns a description for all of the VMs that belong to you. If you provide an invalid VM ID, an error is returned. If you provide the ID of a VM that does not belong to you, the description of this VM is not included in the response. The refresh interval for data returned by this action is one hour, meaning that a terminated VM may appear in the response.

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadVms PROFILE \
  --DryRun False \
  --Filters '{ \
      "TagKeys": ["string"], \
      "TagValues": ["string"], \
      "Tags": ["string"], \
      "VmIds": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadVms \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "Filters": { \
    "TagKeys": [ \
      "string" \
    ], \
    "TagValues": [ \
      "string" \
    ], \
    "Tags": [ \
      "string" \
    ], \
    "VmIds": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "Filters": { 
    "TagKeys": ["string"], 
    "TagValues": ["string"], 
    "Tags": ["string"], 
    "VmIds": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadVms', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersVm false One or more filters.
» TagKeys [string] false The keys of the tags associated with the VMs.
» TagValues [string] false The values of the tags associated with the VMs.
» Tags [string] false The key/value combination of the tags associated with the VMs, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.
» VmIds [string] false One or more IDs of VMs.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadVmsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Vms": [
    {
      "Architecture": "string",
      "BlockDeviceMappings": [
        {
          "Bsu": {
            "DeleteOnVmDeletion": true,
            "LinkDate": "2019-08-24",
            "State": "string",
            "VolumeId": "string"
          },
          "DeviceName": "string"
        }
      ],
      "BsuOptimized": true,
      "ClientToken": "string",
      "CreationDate": "string",
      "DeletionProtection": true,
      "Hypervisor": "string",
      "ImageId": "string",
      "IsSourceDestChecked": true,
      "KeypairName": "string",
      "LaunchNumber": 0,
      "NetId": "string",
      "Nics": [
        {
          "AccountId": "string",
          "Description": "string",
          "IsSourceDestChecked": true,
          "LinkNic": {
            "DeleteOnVmDeletion": true,
            "DeviceNumber": 0,
            "LinkNicId": "string",
            "State": "string"
          },
          "LinkPublicIp": {
            "PublicDnsName": "string",
            "PublicIp": "string",
            "PublicIpAccountId": "string"
          },
          "MacAddress": "string",
          "NetId": "string",
          "NicId": "string",
          "PrivateDnsName": "string",
          "PrivateIps": [
            {
              "IsPrimary": true,
              "LinkPublicIp": {
                "PublicDnsName": "string",
                "PublicIp": "string",
                "PublicIpAccountId": "string"
              },
              "PrivateDnsName": "string",
              "PrivateIp": "string"
            }
          ],
          "SecurityGroups": [
            {
              "SecurityGroupId": "string",
              "SecurityGroupName": "string"
            }
          ],
          "State": "string",
          "SubnetId": "string"
        }
      ],
      "OsFamily": "string",
      "Performance": "string",
      "Placement": {
        "SubregionName": "string",
        "Tenancy": "string"
      },
      "PrivateDnsName": "string",
      "PrivateIp": "string",
      "ProductCodes": [
        "string"
      ],
      "PublicDnsName": "string",
      "PublicIp": "string",
      "ReservationId": "string",
      "RootDeviceName": "string",
      "RootDeviceType": "string",
      "SecurityGroups": [
        {
          "SecurityGroupId": "string",
          "SecurityGroupName": "string"
        }
      ],
      "State": "string",
      "StateReason": "string",
      "SubnetId": "string",
      "Tags": [
        {
          "Key": "string",
          "Value": "string"
        }
      ],
      "UserData": "string",
      "VmId": "string",
      "VmInitiatedShutdownBehavior": "string",
      "VmType": "string"
    }
  ]
}

ReadVmsState

POST /ReadVmsState

Lists the status of one or more virtual machines (VMs).

[NOTE]
If you exceed the number of identical requests allowed for a configured time period, the RequestLimitExceeded error message is returned.

Code samples

osc-cli api ReadVmsState PROFILE \
  --AllVms True \
  --DryRun False \
  --Filters '{ \
      "MaintenanceEventCodes": ["string"], \
      "MaintenanceEventDescriptions": ["string"], \
      "MaintenanceEventsNotAfter": ["2019-08-24"], \
      "MaintenanceEventsNotBefore": ["2019-08-24"], \
      "SubregionNames": ["string"], \
      "VmIds": ["string"], \
      "VmStates": ["string"] \
    }' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/ReadVmsState \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "AllVms": true, \
  "DryRun": true, \
  "Filters": { \
    "MaintenanceEventCodes": [ \
      "string" \
    ], \
    "MaintenanceEventDescriptions": [ \
      "string" \
    ], \
    "MaintenanceEventsNotAfter": [ \
      "2019-08-24" \
    ], \
    "MaintenanceEventsNotBefore": [ \
      "2019-08-24" \
    ], \
    "SubregionNames": [ \
      "string" \
    ], \
    "VmIds": [ \
      "string" \
    ], \
    "VmStates": [ \
      "string" \
    ] \
  } \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "AllVms": True,
  "DryRun": False,
  "Filters": { 
    "MaintenanceEventCodes": ["string"], 
    "MaintenanceEventDescriptions": ["string"], 
    "MaintenanceEventsNotAfter": ["2019-08-24"], 
    "MaintenanceEventsNotBefore": ["2019-08-24"], 
    "SubregionNames": ["string"], 
    "VmIds": ["string"], 
    "VmStates": ["string"] 
  }
}

r = requests.post('https://api.{region}.outscale.com/api/v1/ReadVmsState', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
AllVms boolean false If true, includes the status of all VMs. By default or if set to false, only includes the status of running VMs.
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
Filters FiltersVmsState false One or more filters.
» MaintenanceEventCodes [string] false The code for the scheduled event (system-reboot | system-maintenance).
» MaintenanceEventDescriptions [string] false The description of the scheduled event.
» MaintenanceEventsNotAfter [string] false The latest time the event can end.
» MaintenanceEventsNotBefore [string] false The earliest time the event can start.
» SubregionNames [string] false The names of the Subregions of the VMs.
» VmIds [string] false One or more IDs of VMs.
» VmStates [string] false The states of the VMs (pending | running | stopping | stopped | shutting-down | terminated | quarantine).

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). ReadVmsStateResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "VmStates": [
    {
      "MaintenanceEvents": [
        {
          "Code": "string",
          "Description": "string",
          "NotAfter": "2019-08-24",
          "NotBefore": "2019-08-24"
        }
      ],
      "SubregionName": "string",
      "VmId": "string",
      "VmState": "string"
    }
  ]
}

RebootVms

POST /RebootVms

Reboots one or more virtual machines (VMs).
This operation sends a reboot request to one or more specified VMs. This is an asynchronous action that queues this reboot request. This action only reboots VMs that are valid and that belong to you.

Code samples

osc-cli api RebootVms PROFILE \
  --DryRun False \
  --VmIds '["string"]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/RebootVms \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "VmIds": [ \
    "string" \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "VmIds": ["string"]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/RebootVms', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
VmIds [string] true One or more IDs of the VMs you want to reboot.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). RebootVmsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  }
}

StartVms

POST /StartVms

Start one or more virtual machines (VMs).
You can start only VMs that are valid and that belong to you.

Code samples

osc-cli api StartVms PROFILE \
  --DryRun False \
  --VmIds '["string"]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/StartVms \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "VmIds": [ \
    "string" \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "VmIds": ["string"]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/StartVms', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
VmIds [string] true One or more IDs of VMs.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). StartVmsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Vms": [
    {
      "CurrentState": "string",
      "PreviousState": "string",
      "VmId": "string"
    }
  ]
}

StopVms

POST /StopVms

Stops one or more running virtual machines (VMs).
You can stop only VMs that are valid and that belong to you. Data stored in the VM RAM is lost.

Code samples

osc-cli api StopVms PROFILE \
  --DryRun False \
  --ForceStop True \
  --VmIds '["string"]' 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/StopVms \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "DryRun": true, \
  "ForceStop": true, \
  "VmIds": [ \
    "string" \
  ] \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "DryRun": False,
  "ForceStop": True,
  "VmIds": ["string"]
}

r = requests.post('https://api.{region}.outscale.com/api/v1/StopVms', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
DryRun boolean false If true, checks whether you have the required permissions to perform the action.
ForceStop boolean false Forces the VM to stop.
VmIds [string] true One or more IDs of VMs.

Responses

Status Meaning Description Schema
200 OK The HTTP 200 response (OK). StopVmsResponse
400 Bad Request The HTTP 400 response (Bad Request). ErrorResponse
401 Unauthorized The HTTP 401 response (Unauthorized). ErrorResponse
500 Internal Server Error The HTTP 500 response (Internal Server Error). ErrorResponse

Example responses

200 Response

{
  "ResponseContext": {
    "RequestId": "string"
  },
  "Vms": [
    {
      "CurrentState": "string",
      "PreviousState": "string",
      "VmId": "string"
    }
  ]
}

UpdateVm

POST /UpdateVm

Modifies a specific attribute of a virtual machine (VM).
You can modify only one attribute at a time. You can modify the IsSourceDestChecked attribute only if the VM is in a Net.
You must stop the VM before modifying the following attributes:

Code samples

osc-cli api UpdateVm PROFILE \
  --BlockDeviceMappings '[ \
      { \
        "Bsu": {"DeleteOnVmDeletion": True, "VolumeId": "string"}, \
        "DeviceName": "string", \
        "NoDevice": "string", \
        "VirtualDeviceName": "string" \
      } \
    ]' \
  --BsuOptimized True \
  --DeletionProtection True \
  --DryRun False \
  --IsSourceDestChecked True \
  --KeypairName "string" \
  --Performance "medium" \
  --SecurityGroupIds '["string"]' \
  --UserData "string" \
  --VmId "string" \
  --VmInitiatedShutdownBehavior "string" \
  --VmType "string" 

# To use this command, you need to install version 7.75 (or later) of curl and libcurl from https://github.com/curl/curl

curl -X POST https://api.{region}.outscale.com/api/v1/UpdateVm \
  -H 'Content-Type: application/json' \
  -u 'ACCESS_KEY:SECRET_KEY' \
  --aws-sigv4 'osc' \
  -d '{ \
  "BlockDeviceMappings": [ \
    { \
      "Bsu": { \
        "DeleteOnVmDeletion": true, \
        "VolumeId": "string" \
      }, \
      "DeviceName": "string", \
      "NoDevice": "string", \
      "VirtualDeviceName": "string" \
    } \
  ], \
  "BsuOptimized": true, \
  "DeletionProtection": true, \
  "DryRun": true, \
  "IsSourceDestChecked": true, \
  "KeypairName": "string", \
  "Performance": "medium", \
  "SecurityGroupIds": [ \
    "string" \
  ], \
  "UserData": "string", \
  "VmId": "string", \
  "VmInitiatedShutdownBehavior": "string", \
  "VmType": "string" \
}'

import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'API_KEY'
}
params = { 
  "BlockDeviceMappings": [ 
    { 
      "Bsu": { 
        "DeleteOnVmDeletion": True, 
        "VolumeId": "string" 
      }, 
      "DeviceName": "string", 
      "NoDevice": "string", 
      "VirtualDeviceName": "string" 
    } 
  ],
  "BsuOptimized": True,
  "DeletionProtection": True,
  "DryRun": False,
  "IsSourceDestChecked": True,
  "KeypairName": "string",
  "Performance": "medium",
  "SecurityGroupIds": ["string"],
  "UserData": "string",
  "VmId": "string",
  "VmInitiatedShutdownBehavior": "string",
  "VmType": "string"
}

r = requests.post('https://api.{region}.outscale.com/api/v1/UpdateVm', headers = headers, json = params)
print(r.json())

Parameters

Parameter Type Required Description
BlockDeviceMappings [BlockDeviceMappingVmUpdate] false One or more block device mappings of the VM.
» Bsu BsuToUpdateVm false Information about the BSU volume.
»» DeleteOnVmDeletion boolean false If set to true, the volume is deleted when terminating the VM. If set to false, the volume is not deleted when terminating the VM.
»» VolumeId string false The ID of the volume.
» DeviceName string false The name of the device.
» NoDevice string false Removes the device which