API

PageArtefact

Operations

Every route this entity exposes. Each route links to its own reference on this page.

Method Route SDK operation Returns
GET /api/v1/organizations/{organization_id}/artefacts/page list Authorized private Artefacts page
GET /api/v1/organizations/{organization_id}/artefacts/{artefact_ref}/page load Authorized private Artefacts page

Examples

One example per SDK, generated from the API model. The argument names are the parameters and fields of this entity, and the values are placeholders. The examples are not compiled or executed.

Golang

Construct client as shown in the Golang setup, then call the operations:

page_artefacts, err := client.PageArtefact(nil).List(map[string]any{"organization_id": "example"}, nil)
if err != nil {
    panic(err)
}
fmt.Println(page_artefacts)
page_artefact, err := client.PageArtefact(nil).Load(map[string]any{"id": "example_id", "organization_id": "example"}, nil)
if err != nil {
    panic(err)
}
fmt.Println(page_artefact)

Lua

Construct client as shown in the Lua setup, then call the operations:

local page_artefacts, err = client:PageArtefact():list({ organization_id = "example" })
local page_artefact, err = client:PageArtefact():load({ id = "example_id", organization_id = "example" })

PHP

Construct client as shown in the PHP setup, then call the operations:

$page_artefacts = $client->PageArtefact()->list(["organization_id" => "example"]);
$page_artefact = $client->PageArtefact()->load(["id" => "example_id", "organization_id" => "example"]);

Python

Construct client as shown in the Python setup, then call the operations:

page_artefacts = client.PageArtefact().list({"organization_id": "example"})
page_artefact = client.PageArtefact().load({"id": "example_id", "organization_id": "example"})

Ruby

Construct client as shown in the Ruby setup, then call the operations:

page_artefacts = client.PageArtefact.list({ "organization_id" => "example" })
page_artefact = client.PageArtefact.load({ "id" => "example_id", "organization_id" => "example" })

TypeScript

Construct client as shown in the TypeScript setup, then call the operations:

const page_artefacts = await client.PageArtefact().list({ organization_id: "example" })
const page_artefact = await client.PageArtefact().load({ id: "example_id", organization_id: "example" })

Fields

Field Type Required Description
artefact any Yes Artefact
automation one,object,null Yes Automation
automation_invocation_id one,string,null No Automation Invocation Id
byte_size integer Yes Byte Size
checksum_sha256 string Yes Checksum Sha256
comment_threads array Yes Comment Threads
content_type string Yes Content Type
created_at one,string,null No Created At
created_by_user_id one,string,null No Created By User Id
description one,string,null No Description
document_key string No Stable document identity shared by all revisions.
draft one,object,null Yes The autosaved working copy of the newest Markdown version; null for older versions and other files.
entrypoint string No Entrypoint
expires_at one,string,null No Expires At
filename string Yes Filename
files array No Files
harness one,string,null No Harness
harness_version one,string,null No Harness Version
id string Yes Id
kind string Yes Kind
kinds array Yes Kinds
model one,string,null No Model
organization object Yes Organization
organization_id string Yes Organization Id
pagination object Yes Pagination
permissions object Yes Permissions
preview object Yes Preview
published_at one,string,null No Published At
published_at_label one,string,null Yes Published At Label
publisher one,object,null Yes Publisher
repository one,object,null Yes Repository
repository_id one,string,null No Repository Id
selected_path string No Selected Path
slug string Yes Slug
source string Yes Source
status string Yes Status
title string Yes Title
vcs_agent_checkpoint_id one,string,null No Vcs Agent Checkpoint Id
vcs_agent_session_id one,string,null No Vcs Agent Session Id
version integer Yes Version
versions array Yes Versions
view_url string Yes View Url
web_url string Yes Web Url

list

GET /api/v1/organizations/{organization_id}/artefacts/page

Operation ID: page_api_v1_organization_artefacts.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
organization_id path string Yes
page query integer No
q query string No
kind query string No
harness query string No
model query string No
author query string No
repo query string No
slug query string No
source query enum: automation, agent, user No

Responses

200: Authorized private Artefacts page

application/json

Property Type Required Description
artefacts array of object and object Yes
filters object Yes
kinds array of string Yes
organization object Yes
organization.id string Yes
organization.name string Yes
organization.slug string Yes
pagination object Yes
pagination.count integer Yes
pagination.last integer Yes
pagination.next integer No
pagination.page integer Yes
pagination.previous integer No
401: Unauthorized
403: Forbidden
404: Resource not found
422: Invalid selection
502: Bad gateway

load

GET /api/v1/organizations/{organization_id}/artefacts/{artefact_ref}/page

Operation ID: page_api_v1_organization_artefact.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
organization_id path string Yes
artefact_ref path string Yes
version query integer No
versions_page query integer No
file query string No

Responses

200: Authorized private Artefacts page

application/json

Property Type Required Description
artefact object and object Yes
automation object Yes
automation.invocation_id string Yes
automation.name string Yes
automation.slug string Yes
comment_threads array of object Yes
comment_threads[].comments array of object Yes
comment_threads[].comments[].author string Yes
comment_threads[].comments[].author_id string Yes
comment_threads[].comments[].author_kind enum: person, agent Yes
comment_threads[].comments[].body string Yes
comment_threads[].comments[].created_at string (date-time) Yes
comment_threads[].comments[].id string Yes
comment_threads[].id string Yes The anchor key.
comment_threads[].quote string Yes
comment_threads[].resolved boolean Yes
draft object,null Yes The autosaved working copy of the newest Markdown version; null for older versions and other files.
draft.content string,null Yes Null when nothing has been edited since the newest version.
draft.revision integer Yes
draft.updated_by string,null Yes
kinds array of string Yes
organization object Yes
organization.id string Yes
organization.name string Yes
organization.slug string Yes
pagination object Yes
pagination.count integer Yes
pagination.last integer Yes
pagination.next integer No
pagination.page integer Yes
pagination.previous integer No
permissions object Yes
permissions.delete boolean Yes
permissions.edit boolean Yes
permissions.edit_content boolean Yes
preview object Yes
preview.content string No
preview.kind enum: html, pdf, image, markdown, download, unavailable Yes
preview.viewer_url string No
selected_path string No
versions array of object Yes
versions[].id string Yes
versions[].published_at string,null Yes
versions[].version integer Yes
401: Unauthorized
403: Forbidden
404: Resource not found
422: Invalid selection
502: Bad gateway