Skip to main content
Repositories are the top-level containers for organizing your datasets on Alphacast. Use this endpoint to create a new repository under your account. You will automatically become the Owner of any repository you create.

Request

POST https://api.alphacast.io/repositories
Send a JSON body with the Content-Type: application/json header.

Authentication

This endpoint requires HTTP Basic Auth. Pass your API key as the username and leave the password empty.

Body parameters

name
string
required
Display name for the new repository.
privacy
string
required
Visibility setting for the repository. Must be either "Public" or "Private".
description
string
Optional description of the repository’s contents or purpose.
team
string
Optional team name to associate this repository with for collaborative access.

Response

Returns 201 Created with the newly created repository object.
id
integer
Unique numeric identifier assigned to the new repository.
name
string
Display name of the repository.
description
string
Description of the repository, if provided.
privacy
string
Visibility setting. Either "Public" or "Private".
team
string
The team this repository belongs to, if provided.
permission
string
Your access level. Always "Owner" for repositories you create.

Example

curl -u YOUR_API_KEY: \
  -X POST \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Emerging Markets Macro",
    "description": "GDP, inflation, and rates for EM economies",
    "privacy": "Private",
    "team": "research"
  }' \
  https://api.alphacast.io/repositories
{
  "id": 101,
  "name": "Emerging Markets Macro",
  "description": "GDP, inflation, and rates for EM economies",
  "privacy": "Private",
  "team": "research",
  "permission": "Owner"
}