curl --request POST \
--url https://api.cnap.tech/v1/credentials \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"type": "cloud",
"name": "<string>",
"provider": "hcloud",
"api_token": "<string>"
}
'{
"id": "<string>",
"type": "cloud"
}Registers a credential. The secret is stored securely and never persisted in CNAP directly.
curl --request POST \
--url https://api.cnap.tech/v1/credentials \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"type": "cloud",
"name": "<string>",
"provider": "hcloud",
"api_token": "<string>"
}
'{
"id": "<string>",
"type": "cloud"
}Personal Access Token (cnap_pat_...) or OAuth2 JWT. Create tokens at https://cnap.tech/account/tokens