Admin API
Admin API (1.1.0)
List subscriptions
List all subscriptions.
query Parameters
sink | string Filter by the exact specified sink. |
source | string Filter by the exact specified source. |
Responses
Response samples
- 200
{- "subscriptions": [
- {
- "id": "string",
- "source": "string",
- "sink": "string",
- "options": {
- "property1": "string",
- "property2": "string"
}
}
]
}
Create subscription
Create subscription.
Request Body schema: application/jsonrequired
source required | string (Source) Source uri. Accepted forms:
|
sink required | string (Sink) Sink uri. Accepted forms:
|
object or null (Options) Additional options to apply to the subscription. |
Responses
Request samples
- Payload
{- "source": "string",
- "sink": "string",
- "options": {
- "property1": "string",
- "property2": "string"
}
}
Response samples
- 201
- 400
- 403
- 404
- 409
- 500
- 503
{- "id": "string",
- "source": "string",
- "sink": "string",
- "options": {
- "property1": "string",
- "property2": "string"
}
}
Get service handler
Get the handler of a service
path Parameters
service required | string Fully qualified service name. |
handler required | string Handler name. |
Responses
Response samples
- 200
- 400
- 403
- 404
- 409
- 500
- 503
{- "name": "string",
- "ty": "Exclusive",
- "input_description": "string",
- "output_description": "string"
}
List service handlers
List all the handlers of the given service.
path Parameters
service required | string Fully qualified service name. |
Responses
Response samples
- 200
- 400
- 403
- 404
- 409
- 500
- 503
{- "handlers": [
- {
- "name": "string",
- "ty": "Exclusive",
- "input_description": "string",
- "output_description": "string"
}
]
}
Get deployment
Get deployment metadata
path Parameters
deployment required | string Deployment identifier |
Responses
Response samples
- 200
- 400
- 403
- 404
- 409
- 500
- 503
{- "arn": "string",
- "assume_role_arn": "string",
- "additional_headers": {
- "property1": "string",
- "property2": "string"
}, - "created_at": "string",
- "min_protocol_version": 0,
- "max_protocol_version": 0,
- "id": "string",
- "services": [
- {
- "name": "string",
- "handlers": [
- {
- "name": "string",
- "ty": "Exclusive",
- "input_description": "string",
- "output_description": "string"
}
], - "ty": "Service",
- "deployment_id": "string",
- "revision": 0,
- "public": true,
- "idempotency_retention": "string",
- "workflow_completion_retention": "string"
}
]
}
Delete deployment
Delete deployment. Currently it's supported to remove a deployment only using the force flag
path Parameters
deployment required | string Deployment identifier |
query Parameters
force | boolean If true, the deployment will be forcefully deleted. This might break in-flight invocations, use with caution. |
Responses
Response samples
- 400
- 403
- 404
- 409
- 500
- 503
{- "message": "string",
- "restate_code": "string"
}
Response samples
- 200
{- "deployments": [
- {
- "id": "string",
- "services": [
- {
- "name": "string",
- "revision": 0
}
], - "uri": "string",
- "protocol_type": "RequestResponse",
- "http_version": "string",
- "additional_headers": {
- "property1": "string",
- "property2": "string"
}, - "created_at": "string",
- "min_protocol_version": 0,
- "max_protocol_version": 0
}
]
}
Create deployment
Create deployment. Restate will invoke the endpoint to gather additional information required for registration, such as the services exposed by the deployment. If the deployment is already registered, this method will fail unless force
is set to true
.
Request Body schema: application/jsonrequired
uri required | string (Uri) Uri to use to discover/invoke the http deployment. |
object or null (Additional headers) Additional headers added to the discover/invoke requests to the deployment. | |
use_http_11 | boolean (Use http1.1) Default: false If |
force | boolean (Force) Default: true If By default, this is See the versioning documentation for more information. |
dry_run | boolean (Dry-run mode) Default: false If |
Responses
Request samples
- Payload
{- "arn": "string",
- "assume_role_arn": "string",
- "additional_headers": {
- "property1": "string",
- "property2": "string"
}, - "force": true,
- "dry_run": false
}
Response samples
- 201
- 400
- 403
- 404
- 409
- 500
- 503
{- "id": "string",
- "services": [
- {
- "name": "string",
- "handlers": [
- {
- "name": "string",
- "ty": "Exclusive",
- "input_description": "string",
- "output_description": "string"
}
], - "ty": "Service",
- "deployment_id": "string",
- "revision": 0,
- "public": true,
- "idempotency_retention": "string",
- "workflow_completion_retention": "string"
}
]
}
Delete an invocation
Delete the given invocation. By default, an invocation is terminated by gracefully cancelling it. This ensures virtual object state consistency. Alternatively, an invocation can be killed which does not guarantee consistency for virtual object instance state, in-flight invocations to other services, etc. A stored completed invocation can also be purged
path Parameters
invocation_id required | string Invocation identifier. |
query Parameters
mode | string (DeletionMode) Enum: "Cancel" "Kill" "Purge" If cancel, it will gracefully terminate the invocation. If kill, it will terminate the invocation with a hard stop. If purge, it will only cleanup the response for completed invocations, and leave unaffected an in-flight invocation. |
Responses
Response samples
- 400
- 403
- 404
- 409
- 500
- 503
{- "message": "string",
- "restate_code": "string"
}
Get service
Get a registered service.
path Parameters
service required | string Fully qualified service name. |
Responses
Response samples
- 200
- 400
- 403
- 404
- 409
- 500
- 503
{- "name": "string",
- "handlers": [
- {
- "name": "string",
- "ty": "Exclusive",
- "input_description": "string",
- "output_description": "string"
}
], - "ty": "Service",
- "deployment_id": "string",
- "revision": 0,
- "public": true,
- "idempotency_retention": "string",
- "workflow_completion_retention": "string"
}
Modify a service
Modify a registered service.
path Parameters
service required | string Fully qualified service name. |
Request Body schema: application/jsonrequired
public | boolean or null (Public) If true, the service can be invoked through the ingress. If false, the service can be invoked only from another Restate service. |
idempotency_retention | string or null (Idempotency retention) Modify the retention of idempotent requests for this service. Can be configured using the |
workflow_completion_retention | string or null (Workflow completion retention) Modify the retention of the workflow completion. This can be modified only for workflow services! Can be configured using the |
Responses
Request samples
- Payload
{- "public": true,
- "idempotency_retention": "string",
- "workflow_completion_retention": "string"
}
Response samples
- 200
- 400
- 403
- 404
- 409
- 500
- 503
{- "name": "string",
- "handlers": [
- {
- "name": "string",
- "ty": "Exclusive",
- "input_description": "string",
- "output_description": "string"
}
], - "ty": "Service",
- "deployment_id": "string",
- "revision": 0,
- "public": true,
- "idempotency_retention": "string",
- "workflow_completion_retention": "string"
}
Response samples
- 200
- 400
- 403
- 404
- 409
- 500
- 503
{- "services": [
- {
- "name": "string",
- "handlers": [
- {
- "name": "string",
- "ty": "Exclusive",
- "input_description": "string",
- "output_description": "string"
}
], - "ty": "Service",
- "deployment_id": "string",
- "revision": 0,
- "public": true,
- "idempotency_retention": "string",
- "workflow_completion_retention": "string"
}
]
}
Modify a service state
Modify service state
path Parameters
service required | string Fully qualified service name. |
Request Body schema: application/jsonrequired
version | string or null (Version) If set, the latest version of the state is compared with this value and the operation will fail when the versions differ. |
object_key required | string (Service key) To what virtual object key to apply this change |
required | object (New State) The new state to replace the previous state with |
Responses
Request samples
- Payload
{- "version": "string",
- "object_key": "string",
- "new_state": {
- "property1": [
- 0
], - "property2": [
- 0
]
}
}
Response samples
- 400
- 403
- 404
- 409
- 500
- 503
{- "message": "string",
- "restate_code": "string"
}
Response samples
- 200
{- "property1": "string",
- "property2": "string"
}