Create Application (API)​
Create a new API client. The client id will be generated and returned in the response. Depending on the chosen configuration also a secret will be generated and returned.
Path Parameters
Header Parameters
The default is always the organization of the requesting user. If you like to change/get objects of another organization include the header. Make sure the requesting user has permission to access the requested data.
Request Body required
Possible values: non-empty
and <= 200 characters
Possible values: [API_AUTH_METHOD_TYPE_BASIC
, API_AUTH_METHOD_TYPE_PRIVATE_KEY_JWT
]
Default value: API_AUTH_METHOD_TYPE_BASIC
Request Body required
Possible values: non-empty
and <= 200 characters
Possible values: [API_AUTH_METHOD_TYPE_BASIC
, API_AUTH_METHOD_TYPE_PRIVATE_KEY_JWT
]
Default value: API_AUTH_METHOD_TYPE_BASIC
Request Body required
Possible values: non-empty
and <= 200 characters
Possible values: [API_AUTH_METHOD_TYPE_BASIC
, API_AUTH_METHOD_TYPE_PRIVATE_KEY_JWT
]
Default value: API_AUTH_METHOD_TYPE_BASIC
- 200
- default
A successful response.
Schema
details object
generated secret for this config
generated secret for this config
{
"appId": "string",
"details": {
"sequence": "2",
"creationDate": "2024-04-10T04:31:16.326Z",
"changeDate": "2024-04-10T04:31:16.326Z",
"resourceOwner": "69629023906488334"
},
"clientId": "3950723409029374",
"clientSecret": "gjoq34589uasgh"
}
Schema
details object
generated secret for this config
generated secret for this config
{
"appId": "string",
"details": {
"sequence": "2",
"creationDate": "2024-04-10T04:31:16.326Z",
"changeDate": "2024-04-10T04:31:16.326Z",
"resourceOwner": "69629023906488334"
},
"clientId": "3950723409029374",
"clientSecret": "gjoq34589uasgh"
}
Schema
details object
generated secret for this config
generated secret for this config
{
"appId": "string",
"details": {
"sequence": "2",
"creationDate": "2024-04-10T04:31:16.326Z",
"changeDate": "2024-04-10T04:31:16.326Z",
"resourceOwner": "69629023906488334"
},
"clientId": "3950723409029374",
"clientSecret": "gjoq34589uasgh"
}
An unexpected error response.
Schema
details object[]
{
"code": 0,
"message": "string",
"details": [
{
"@type": "string"
}
]
}
Schema
details object[]
{
"code": 0,
"message": "string",
"details": [
{
"@type": "string"
}
]
}
Schema
details object[]
{
"code": 0,
"message": "string",
"details": [
{
"@type": "string"
}
]
}
POST /projects/:projectId/apps/api
Authorization
name: OAuth2type: oauth2scopes:openid,urn:zitadel:iam:org:project:id:zitadel:aud
flows: { "authorizationCode": { "authorizationUrl": "$CUSTOM-DOMAIN/oauth/v2/authorize", "tokenUrl": "$CUSTOM-DOMAIN/oauth/v2/token", "scopes": { "openid": "openid", "urn:zitadel:iam:org:project:id:zitadel:aud": "urn:zitadel:iam:org:project:id:zitadel:aud" } } }
Request
Request
curl -L -X POST 'https://$CUSTOM-DOMAIN/management/v1/projects/:projectId/apps/api' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"name": "MyAPIApp",
"authMethodType": "API_AUTH_METHOD_TYPE_BASIC"
}'
curl -L -X POST 'https://$CUSTOM-DOMAIN/management/v1/projects/:projectId/apps/api' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"name": "MyAPIApp",
"authMethodType": "API_AUTH_METHOD_TYPE_BASIC"
}'
curl -L -X POST 'https://$CUSTOM-DOMAIN/management/v1/projects/:projectId/apps/api' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"name": "MyAPIApp",
"authMethodType": "API_AUTH_METHOD_TYPE_BASIC"
}'
curl -L -X POST 'https://$CUSTOM-DOMAIN/management/v1/projects/:projectId/apps/api' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"name": "MyAPIApp",
"authMethodType": "API_AUTH_METHOD_TYPE_BASIC"
}'
curl -L -X POST 'https://$CUSTOM-DOMAIN/management/v1/projects/:projectId/apps/api' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"name": "MyAPIApp",
"authMethodType": "API_AUTH_METHOD_TYPE_BASIC"
}'
curl -L -X POST 'https://$CUSTOM-DOMAIN/management/v1/projects/:projectId/apps/api' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"name": "MyAPIApp",
"authMethodType": "API_AUTH_METHOD_TYPE_BASIC"
}'
curl -L -X POST 'https://$CUSTOM-DOMAIN/management/v1/projects/:projectId/apps/api' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"name": "MyAPIApp",
"authMethodType": "API_AUTH_METHOD_TYPE_BASIC"
}'
curl -L -X POST 'https://$CUSTOM-DOMAIN/management/v1/projects/:projectId/apps/api' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"name": "MyAPIApp",
"authMethodType": "API_AUTH_METHOD_TYPE_BASIC"
}'
curl -L -X POST 'https://$CUSTOM-DOMAIN/management/v1/projects/:projectId/apps/api' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"name": "MyAPIApp",
"authMethodType": "API_AUTH_METHOD_TYPE_BASIC"
}'