Skip to main content

API Authentication

Before sending a REST request to the API, you get an OSTOKEN as follows:

export OS_AUTH_URL=
export OS_USER_DOMAIN_NAME=your_user_domain_name
export OS_PROJECT_NAME=your_project_name
export OS_USERNAME=your_username
export OS_PASSWORD=your_password
OSTOKEN=$(openstack token issue -c "id" -f value)

Then set the OSTOKEN in the HTTP header X-Auth-Token to authenticate a REST request.

curl \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--header "X-Auth-Token: $OSTOKEN"

TTL token limit: The OSTOKEN issued by Open Telekom Cloud has a default TTL of 24 hours. However, the Cloud Topology Designer only accept the OSTOKEN in the API requests with the TTL of 30 minutes to prevent a stolen token.