List where a data block's versions run
const url = 'https://example.com/v1/blocks/example/runs-in';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://example.com/v1/blocks/example/runs-in \ --header 'Authorization: Bearer <token>'Where the block’s versions run now: one row for each project, and each segment pin inside one, whose running version of an agent pins a version of the block (as a prompt, a settings block or its model settings). Each agent’s projects are the ones agents.projects lists, and what runs in each is what it says: a pin that covers the project, else its Latest. Only the projects the caller can read are named, and an agent version the caller can’t see is left out. A block no running version pins answers an empty list. Without the agents’ pins and Latest in this runtime, 501 runs-in-unsupported.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Responses
Section titled “Responses”Where it runs.
object
Example
{ "data": [ { "follows": "pin", "inYourFiles": { "state": "yes", "pr": { "state": "open" } } } ]}Missing / malformed / expired / revoked bearer token.
object
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}block-not-found: no such block, or one in a project the caller can’t read.
object
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}rate-limit-exceeded with details.limit: "api-requests", on a runtime that sets workspace limits (Kindgi Cloud): this workspace’s limit on API requests a minute is reached, so the request wasn’t run; Retry-After says when to send it again.
object
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}Headers
Section titled “Headers”runs-in-unsupported: this runtime doesn’t read the agents’ pins and Latest.
object
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}The database was too busy to answer in time (database-busy), or the authorization store couldn’t be reached (authz-backend-unavailable); Retry-After (whole seconds) says when to try again.
object
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}Headers
Section titled “Headers”See also
GET /v1/blocks/{blockId}: Fetch a data block (latest version)GET /v1/blocks/{blockId}/versions: List versions of a data blockGET /v1/blocks/{blockId}/versions/{version}: Fetch a specific data block versionPOST /v1/blocks/{blockId}/versions/{version}/unregister: Unregister a data block version- Kindgi 0.4.0
- Error code
authz-backend-unavailable - Error code
block-not-found - Error code
database-busy - Error code
rate-limit-exceeded - Error code
runs-in-unsupported - Every error code