A valid request URL is required to generate request examples{
"srn": "srn2:service-token#a1B2c3D4e5F6g7H8",
"description": "CI pipeline token for nightly ingestion",
"accessKey": "a1B2c3D4e5F6g7H8",
"secretKey": "<string>",
"bearerToken": "<string>",
"ttl": 123,
"createdAt": "2024-09-04T00:28:30.876+00:00",
"lastUpdatedAt": "2024-09-04T00:28:30.876+00:00",
"createdBy": "srn:zone:user:default:abcd1234",
"lastUpdatedBy": "srn:zone:user:default:abcd1234"
}{
"timestamp": "2023-11-07T05:31:56Z",
"status": 404,
"error": "Not Found",
"message": "Not Found.",
"path": "/api/v1/rbac-manager/policies/srn2:policy%23missing"
}{
"timestamp": "2023-11-07T05:31:56Z",
"status": 404,
"error": "Not Found",
"message": "Not Found.",
"path": "/api/v1/rbac-manager/policies/srn2:policy%23missing"
}Create a service token
Creates a service token and returns its access key, secret key, and the full bearer token
(st-<accessKey>-<secretKey>). Save the secret key and bearer token from this response: they cannot be
retrieved again.
A new token has no permissions. Assign it a role with POST /roles/{roleSrn}/create-assignment,
using subjectType: service-token and the access key as the subject.
A valid request URL is required to generate request examples{
"srn": "srn2:service-token#a1B2c3D4e5F6g7H8",
"description": "CI pipeline token for nightly ingestion",
"accessKey": "a1B2c3D4e5F6g7H8",
"secretKey": "<string>",
"bearerToken": "<string>",
"ttl": 123,
"createdAt": "2024-09-04T00:28:30.876+00:00",
"lastUpdatedAt": "2024-09-04T00:28:30.876+00:00",
"createdBy": "srn:zone:user:default:abcd1234",
"lastUpdatedBy": "srn:zone:user:default:abcd1234"
}{
"timestamp": "2023-11-07T05:31:56Z",
"status": 404,
"error": "Not Found",
"message": "Not Found.",
"path": "/api/v1/rbac-manager/policies/srn2:policy%23missing"
}{
"timestamp": "2023-11-07T05:31:56Z",
"status": 404,
"error": "Not Found",
"message": "Not Found.",
"path": "/api/v1/rbac-manager/policies/srn2:policy%23missing"
}Authorizations
A StarTree API token or a service token (st-<accessKey>-<secretKey>).
Body
"CI pipeline token for nightly ingestion"
Response
The new token, including its secret key.
"srn2:service-token#a1B2c3D4e5F6g7H8"
"CI pipeline token for nightly ingestion"
Public identifier of the token. Use it as the subject when assigning a role.
"a1B2c3D4e5F6g7H8"
Returned only in this response.
The full token to send in the Authorization header, formatted st-<accessKey>-<secretKey>. Returned only in this response.
Time to live in seconds, or null if the token does not expire.
"2024-09-04T00:28:30.876+00:00"
"2024-09-04T00:28:30.876+00:00"
SRN of the principal that created the resource. Predefined StarTree resources show startree-rbac-manager.
"srn:zone:user:default:abcd1234"
"srn:zone:user:default:abcd1234"
Was this page helpful?

