Skip to main content
GET
/
v1
/
organizations
/
{organizationId}
/
projects
/
{projectId}
/
components
/
{id}
/
versions
List Component Versions
curl --request GET \
  --url https://api.example.com/v1/organizations/{organizationId}/projects/{projectId}/components/{id}/versions
{
  "data": [
    {}
  ],
  "pagination": {}
}

Path Parameters

organizationId
string
required
Organization ID
projectId
string
required
Project ID
id
string
required
Component ID

Query Parameters

page
number
default:"1"
Page number
limit
number
default:"20"
Items per page

Response

data
ComponentVersion[]
Array of version objects
pagination
object
Pagination information

Example Response

{
  "data": [
    {
      "version": 3,
      "status": "published",
      "content": "const metadata = () => ({...});\nconst body = (props) => {...};",
      "compiled": "const metadata = () => ({...});\nconst body = (props) => {...};",
      "schema": {...},
      "createdAt": "2024-03-22T10:00:00Z",
      "createdBy": "user123",
      "packageVersion": "2.0.0"
    },
    {
      "version": 2,
      "status": "published",
      "content": "...",
      "compiled": "...",
      "schema": {...},
      "createdAt": "2024-03-15T10:00:00Z",
      "createdBy": "user123",
      "packageVersion": "1.1.0"
    },
    {
      "version": 1,
      "status": "published",
      "content": "...",
      "compiled": "...",
      "schema": {...},
      "createdAt": "2024-03-10T10:00:00Z",
      "createdBy": "user456",
      "packageVersion": "1.0.0"
    }
  ],
  "pagination": {
    "page": 1,
    "limit": 20,
    "total": 3,
    "pages": 1
  }
}
Component versions are created when the component is included in a package. Each version is immutable and tied to a specific package version.

Code Examples

curl -X GET "https://api.metabind.ai/v1/organizations/org123/projects/proj456/components/c123/versions" \
  -H "Authorization: Bearer YOUR_API_KEY"