Skip to main content

Documentation Index

Fetch the complete documentation index at: https://visual-layer-my-changes.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

How This Helps

Dataset sharing lets you collaborate with teammates without duplicating data. You can grant access to reviewers, annotators, or developers using a single API call.

Prerequisites

  • A dataset ID (visible in the browser URL when viewing a dataset: https://app.visual-layer.com/dataset/<dataset_id>/data).
  • A valid JWT token. See Authentication.
  • The recipient must be a registered Visual Layer user.

Share a Dataset

Grant another user access to your dataset by sending their email address in a PUT request.
PUT /api/v1/manage/{dataset_id}/invite
Authorization: Bearer <jwt>
Content-Type: application/json

Parameters

ParameterTypeRequiredDescription
grant_to_user_emailstringYesEmail address of the user to grant access. Must be a registered Visual Layer account.

Example

curl -X PUT \
  -H "Authorization: Bearer <jwt>" \
  -H "Content-Type: application/json" \
  -d '{"grant_to_user_email": "colleague@example.com"}' \
  "https://app.visual-layer.com/api/v1/manage/<dataset_id>/invite"
A successful request returns HTTP 200 with a null body.

List Dataset Members

Retrieve the list of users who currently have access to a dataset.
GET /api/v1/manage/{dataset_id}/share
Authorization: Bearer <jwt>

Example

curl -H "Authorization: Bearer <jwt>" \
  "https://app.visual-layer.com/api/v1/manage/<dataset_id>/share"

Response

[
  {
    "email": "owner@example.com",
    "role": "owner"
  },
  {
    "email": "colleague@example.com",
    "role": "viewer"
  }
]

Python Example

import requests

VL_BASE_URL = "https://app.visual-layer.com"
JWT_TOKEN = "<your-jwt-token>"
DATASET_ID = "<your-dataset-id>"

headers = {"Authorization": f"Bearer {JWT_TOKEN}"}

# Share dataset with a colleague
resp = requests.put(
    f"{VL_BASE_URL}/api/v1/manage/{DATASET_ID}/invite",
    headers={**headers, "Content-Type": "application/json"},
    json={"grant_to_user_email": "colleague@example.com"},
)
resp.raise_for_status()
print("Dataset shared successfully.")

# List current members
resp = requests.get(
    f"{VL_BASE_URL}/api/v1/manage/{DATASET_ID}/share",
    headers=headers,
)
resp.raise_for_status()
members = resp.json()
print(f"Dataset has {len(members)} member(s):")
for member in members:
    print(f"  {member['email']}{member['role']}")

Response Codes

See Error Handling for the error response format and Python handling patterns.

Invite (PUT /api/v1/manage/{dataset_id}/invite)

HTTP CodeMeaning
200User access granted successfully.
401Unauthorized — check your JWT token.
404Dataset not found, or the specified email does not match a registered Visual Layer account.

List Members (GET /api/v1/manage/{dataset_id}/share)

HTTP CodeMeaning
200Members list returned successfully.
401Unauthorized — check your JWT token.
404Dataset not found.

Add Media to an Existing Dataset

Add new images or videos to an indexed dataset.

Export a Dataset

Export dataset media and metadata.