curl --request POST \
--url https://api.example.com/v1/organizations/{organizationId}/projects \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"slug": "<string>",
"description": "<string>",
"settings": {},
"settings.defaultLocale": "<string>",
"settings.supportedLocales": [
"<string>"
],
"settings.defaultPlatform": "<string>",
"settings.supportedPlatforms": [
"<string>"
],
"settings.thumbnailUrl": "<string>"
}
'Create a new project
curl --request POST \
--url https://api.example.com/v1/organizations/{organizationId}/projects \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"slug": "<string>",
"description": "<string>",
"settings": {},
"settings.defaultLocale": "<string>",
"settings.supportedLocales": [
"<string>"
],
"settings.defaultPlatform": "<string>",
"settings.supportedPlatforms": [
"<string>"
],
"settings.thumbnailUrl": "<string>"
}
'mobile, tablet, or desktop{
"name": "Product Documentation",
"slug": "product-docs",
"description": "Documentation site for products",
"settings": {
"defaultLocale": "en-US",
"supportedLocales": ["en-US", "es-ES"],
"defaultPlatform": "desktop",
"supportedPlatforms": ["desktop", "mobile", "tablet"],
"thumbnailUrl": "https://cdn.acme.com/thumbnails/product-docs.png"
}
}
{
"id": "proj789",
"organizationId": "org123",
"name": "Product Documentation",
"slug": "product-docs",
"description": "Documentation site for products",
"status": "active",
"environment": "development",
"settings": {
"defaultLocale": "en-US",
"supportedLocales": ["en-US", "es-ES"],
"defaultPlatform": "desktop",
"supportedPlatforms": ["desktop", "mobile", "tablet"],
"thumbnailUrl": "https://cdn.acme.com/thumbnails/product-docs.png"
},
"dependencies": [],
"permissions": {
"public": false
},
"metadata": {
"createdBy": "user123"
},
"createdAt": "2024-03-22T10:00:00Z",
"updatedAt": "2024-03-22T10:00:00Z"
}
{
"error": {
"code": "SLUG_ALREADY_EXISTS",
"message": "A project with this slug already exists",
"details": {
"slug": "product-docs"
}
}
}
{
"error": {
"code": "MAX_PROJECTS_REACHED",
"message": "Organization has reached maximum project limit",
"details": {
"maxProjects": 10,
"currentProjects": 10
}
}
}
curl -X POST "https://api.metabind.ai/v1/organizations/org123/projects" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Product Documentation",
"slug": "product-docs",
"description": "Documentation site for products",
"settings": {
"defaultLocale": "en-US",
"supportedLocales": ["en-US", "es-ES"]
}
}'