Enable the service via API
Before you can run commands remotely, the STACKIT Run Command Service first needs to be enabled in the project.
The following documentation describes in simple steps how to enable the STACKIT Run Command Service via API.
Prerequisites
Section titled “Prerequisites”- You have created a service account. Create, manage and delete service accounts
- You have assigned the required project permissions to this service account. Assign roles to a user or service account
- You have created an Access Token for this service account. Aquire short lived access tokens
Your Service Account needs the role Project Editor.
How to enable the Run Command service via API
Section titled “How to enable the Run Command service via API”You need to provide the following information in your API request:
projectId
Use the following POST request to enable the Run Command Service:
POST https://service-enablement.api.eu01.stackit.cloud/v1/projects/{projectId}/services/cloud.stackit.run-command
Authorization: Bearer <service_account_token>How to disable the Run Command service via API
Section titled “How to disable the Run Command service via API”You need to provide the following information in your API request:
projectId
Use the following POST request to disable the Run Command Service:
DELETE https://service-enablement.api.eu01.stackit.cloud/v1/projects/{projectId}/services/cloud.stackit.run-command
Authorization: Bearer <service_account_token>