# Tool artifacts

Source: https://projectfeed.app/docs/api/tool-artifacts

Keep an installed tool's source object linked to the same Project Feed project across repeated publishes.

-   [Plan Free for reads, Pro or Enterprise for writes](https://projectfeed.app/docs/billing)
-   [Scopes projects:read, posts:write, media:write](https://projectfeed.app/docs/api/scopes)

## Endpoints

### GET /api/v1/tool-artifacts

Scope

projects:read

Query parameters

-   `provider` string required
    
    unreal, blender, steamworks, godot, or aseprite
    
-   `external_artifact_id` string required
    
    Stable source identity supplied by the installed tool, up to 500 characters
    

Request

curl

```
curl --request GET \
  --url 'https://projectfeed.app/api/v1/tool-artifacts?provider=provider_abc123&external_artifact_id=external_artifact_id_abc123' \
  --header 'Authorization: Bearer pf_YOUR_API_KEY'
```

Response

JSON

```
{
  "_id": "art_abc123",
  "_creationTime": 1779600000000,
  "organizationId": "ws_abc123",
  "projectId": "prj_abc123",
  "provider": "blender",
  "externalArtifactId": "blend:file-uuid:collection:hero",
  "displayName": "Hero collection",
  "postId": "pst_abc123",
  "latestAttachmentId": "att_abc123",
  "context": {
    "hostVersion": "4.5.1",
    "artifactType": "collection",
    "sourceRevision": "abc123"
  },
  "createdBy": "usr_abc123",
  "createdAt": 1779600000000,
  "updatedAt": 1779680000000
}
```

### GET /api/v1/tool-artifacts

Scope

projects:read

Query parameters

-   `postId` string
    
    Post ID, number, or identifier. Give this or projectId.
    
-   `projectId` string
    
    Project ID or slug. Give this or postId.
    
-   `provider` string
    
    Only artifacts from this tool. Defaults to the tool for a tool credential.
    
-   `limit` number
    
    Page size, 1 to 100. Defaults to 50.
    
-   `cursor` string
    
    nextCursor from the previous page
    

Request

curl

```
curl --request GET \
  --url 'https://projectfeed.app/api/v1/tool-artifacts' \
  --header 'Authorization: Bearer pf_YOUR_API_KEY'
```

Response

JSON

```
{
  "artifacts": [
    {
      "_id": "art_abc123",
      "_creationTime": 1779600000000,
      "organizationId": "ws_abc123",
      "projectId": "prj_abc123",
      "provider": "blender",
      "externalArtifactId": "blend:file-uuid:collection:hero",
      "displayName": "Hero collection",
      "postId": "pst_abc123",
      "latestAttachmentId": "att_abc123",
      "context": {
        "hostVersion": "4.5.1",
        "artifactType": "collection",
        "sourceRevision": "abc123"
      },
      "createdBy": "usr_abc123",
      "createdAt": 1779600000000,
      "updatedAt": 1779680000000
    }
  ],
  "hasMore": false,
  "nextCursor": null
}
```

### PUT /api/v1/tool-artifacts

Scopes

posts:write

media:write

Body parameters

-   `projectId` string required
    
    Project that owns this source identity
    
-   `provider` string required
    
    unreal, blender, steamworks, godot, or aseprite
    
-   `externalArtifactId` string required
    
    Stable identity that does not change between publishes, up to 500 characters
    
-   `displayName` string required
    
    Current source artifact name, up to 200 characters
    
-   `postId` string
    
    Latest post created for the artifact
    
-   `attachmentId` string
    
    Latest file created for the artifact. Its post becomes the artifact's post.
    
-   `context` object
    
    Bounded host, document, revision, selection, layer, and attribute data. Replaces the stored context.
    
-   `createOnly` boolean
    
    Return 409 instead of updating an existing artifact identity
    

Request

curl

```
curl --request PUT \
  --url 'https://projectfeed.app/api/v1/tool-artifacts' \
  --header 'Authorization: Bearer pf_YOUR_API_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
  "projectId": "prj_abc123",
  "provider": "provider_abc123",
  "externalArtifactId": "externalArtifactId_abc123",
  "displayName": "Alex Rivera"
}'
```

Response

JSON

```
{
  "_id": "art_abc123",
  "_creationTime": 1779600000000,
  "organizationId": "ws_abc123",
  "projectId": "prj_abc123",
  "provider": "blender",
  "externalArtifactId": "blend:file-uuid:collection:hero",
  "displayName": "Hero collection",
  "postId": "pst_abc123",
  "latestAttachmentId": "att_abc123",
  "context": {
    "hostVersion": "4.5.1",
    "artifactType": "collection",
    "sourceRevision": "abc123"
  },
  "createdBy": "usr_abc123",
  "createdAt": 1779600000000,
  "updatedAt": 1779680000000
}
```

### DELETE /api/v1/tool-artifacts

Scopes

posts:write

media:write

Query parameters

-   `provider` string required
    
    unreal, blender, steamworks, godot, or aseprite
    
-   `external_artifact_id` string required
    
    Stable source identity supplied by the installed tool
    

Request

curl

```
curl --request DELETE \
  --url 'https://projectfeed.app/api/v1/tool-artifacts?provider=blender&external_artifact_id=blend%3Afile-uuid%3Acollection%3Ahero' \
  --header 'Authorization: Bearer pf_YOUR_API_KEY'
```

Response

JSON

```
{
  "provider": "blender",
  "externalArtifactId": "blend:file-uuid:collection:hero",
  "deleted": true
}
```

## Stable identity

The workspace, provider, and external artifact ID identify one source artifact. Once created, that identity cannot move to another project. Saving a mapping again updates its name, post, file, and context. Changing the post without sending a file clears the stored file.

Lookups, lists, and saves return the stored mapping. Rely on `_id`, `projectId`, `provider`, `externalArtifactId`, `displayName`, `postId`, `latestAttachmentId`, `context`, `createdBy`, `createdAt`, and `updatedAt`. Other fields can appear and are not part of the API. A lookup leaves out `postId` and `latestAttachmentId` when that post or file has been deleted. A delete removes only the mapping and returns the provider, the external artifact ID, and `deleted: true`.

## Context limits

Total size

16 KB of JSON.

Strings

Every text value, selection ID, and attribute name is 500 characters or less.

selectionIds

Up to 200 IDs.

layers

Up to 500. Each layer has string name, path, and kind fields, a boolean visible field, and an integer opacity from 0 to 255.

attributes

Up to 64 string, number, or boolean values.

Other fields

hostVersion, documentName, artifactType, sourceProvider, sourceRevision, and sourceBranch, all strings.

## Preserve one source identity

1.  1.
    
    ### Derive a stable ID
    
    Build `externalArtifactId` from stable source data, not a display name, local path, or current selection index.
    
2.  2.
    
    ### Look it up before publishing
    
    Reuse the returned project and post mapping when it exists.
    
3.  3.
    
    ### Create the first mapping with createOnly
    
    Set createOnly to true when concurrent publishers could race.
    
4.  4.
    
    ### Update it after publishing
    
    Send the new post or file ID and the current source context.
    
5.  5.
    
    ### Read it back
    
    Confirm it still points to the intended project and latest records.
    

## Fix an artifact mapping

### 404 Artifact not found

Confirm the selected workspace, provider, and exact external artifact ID. A lookup never searches by display name.

### 404 Project not found

The project does not exist, is archived, or you cannot access it. Saving a mapping needs a project you can write to.

### 409 Create conflict

Another publisher created the same identity. Read the existing mapping and continue only if its project and provider match the intended source.

### 400 Artifact identity is already bound to another project

A source identity stays with its first project. Create a new stable external ID when the source object is intentionally forked into another project.

### 403 Tool provider does not match this credential

A provider-bound installed tool credential can only read or write its own provider. Use the credential issued for the publishing tool.

### 400 on context

Reduce the context below the limits above. The whole request body must also stay under 32 KB. Keep large source data in the source tool instead of the mapping.

## Next steps

-   [Publish from installed tools](https://projectfeed.app/docs/installed-tools/publish) shows the full publish flow.
-   [Authentication](https://projectfeed.app/docs/api/authentication) covers the credential an installed tool sends.
