POST
/
v0
/
project
/
{project_name}
/
contexts
/
add_logs
curl --request POST \
  --url 'https://api.unify.ai/v0/project/my_project/contexts/add_logs' \
  --header "Authorization: Bearer $UNIFY_KEY"
  --header 'Content-Type: application/json' \
  --data '{
    "context_name": "experiment1/trial1",
    "log_ids": [
        123,
        456,
        789
    ]
}'
{
    "info": "Logs added to context successfully!"
}

Adds existing logs to a context within a project. The logs must already exist in the project and can be specified by their IDs. The same logs can be associated with multiple contexts.

Authorizations

Authorization
string
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

project_name
string
required

Name of the project to create context in.

Body

context_name
string
required

Name of the context to add logs to.

log_ids
[integer]
required

List of log IDs to add to the context. At least one log ID must be provided.

curl --request POST \
  --url 'https://api.unify.ai/v0/project/my_project/contexts/add_logs' \
  --header "Authorization: Bearer $UNIFY_KEY"
  --header 'Content-Type: application/json' \
  --data '{
    "context_name": "experiment1/trial1",
    "log_ids": [
        123,
        456,
        789
    ]
}'
{
    "info": "Logs added to context successfully!"
}