scenarios_list
List registered scenarios for a tenant and namespace.
Key notes
- Requires tenant_id and namespace_id.
- Returns scenario identifiers and hashes.
Inputs
cursor(optional): One of 2 schema variants.limit(optional): Maximum number of records to return.namespace_id(required): Namespace identifier.tenant_id(required): Tenant identifier.
Input Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false,
"properties": {
"cursor": {
"oneOf": [
{
"type": "null"
},
{
"description": "Pagination cursor.",
"type": "string"
}
]
},
"limit": {
"description": "Maximum number of records to return.",
"maximum": 1000,
"minimum": 1,
"type": "integer"
},
"namespace_id": {
"description": "Namespace identifier.",
"minimum": 1,
"type": "integer"
},
"tenant_id": {
"description": "Tenant identifier.",
"minimum": 1,
"type": "integer"
}
},
"required": [
"tenant_id",
"namespace_id"
],
"type": "object"
}
Outputs
items(required): Type: array.next_token(required): One of 2 schema variants.
Output Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false,
"properties": {
"items": {
"items": {
"additionalProperties": false,
"properties": {
"namespace_id": {
"description": "Namespace identifier.",
"minimum": 1,
"type": "integer"
},
"scenario_id": {
"description": "Scenario identifier.",
"type": "string"
},
"spec_hash": {
"additionalProperties": false,
"properties": {
"algorithm": {
"enum": [
"sha256"
],
"type": "string"
},
"value": {
"description": "Lowercase hex digest.",
"type": "string"
}
},
"required": [
"algorithm",
"value"
],
"type": "object"
}
},
"required": [
"scenario_id",
"namespace_id",
"spec_hash"
],
"type": "object"
},
"type": "array"
},
"next_token": {
"oneOf": [
{
"type": "null"
},
{
"description": "Pagination token for the next page.",
"type": "string"
}
]
}
},
"required": [
"items",
"next_token"
],
"type": "object"
}
Examples
List scenarios for a namespace.
Input:
{
"cursor": null,
"limit": 50,
"namespace_id": 1,
"tenant_id": 1
}
Output:
{
"items": [
{
"namespace_id": 1,
"scenario_id": "example-scenario",
"spec_hash": {
"algorithm": "sha256",
"value": "5c3a5b6bce0f4a2c9e22c4fa6a1e6d8d90b0f2dfed1b7f1e9b3d3b3d1f0c9b21"
}
}
],
"next_token": null
}