Pi Durable Platformdocs
ReferenceAdmin

Create a team and assign its first owner

POST
/v1/admin/teams

Request Body

application/json
  1. body
slug*string
name*string
description?string
ownerEmail*string
Formatemail

Response Body

Created

application/json
  1. response
data*
curl -X POST 'https://agents.example.com/v1/admin/teams' \  -H 'Content-Type: application/json' \  -d '{  "slug": "platform-tools",  "name": "Platform Tools",  "ownerEmail": "user@example.com"}'
{  "data": {    "team": {      "team": {        "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",        "slug": "string",        "name": "string",        "description": "string",        "status": "active",        "kind": "team",        "revision": 0,        "createdAt": "2019-08-24T14:15:22Z",        "updatedAt": "2019-08-24T14:15:22Z",        "archivedAt": "2019-08-24T14:15:22Z"      },      "memberCount": 0,      "ownerCount": 0,      "ownerInvites": 0,      "personalOwner": {        "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",        "email": "string",        "displayName": "string",        "status": "active"      }    },    "owner": {      "status": "added",      "member": {        "user": {          "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",          "email": "string",          "displayName": "string",          "status": "active"        },        "role": "owner",        "revision": 0,        "createdAt": "2019-08-24T14:15:22Z"      },      "invite": {        "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",        "email": "string",        "role": "owner",        "invitedBy": "9803bd85-1570-4d91-99f5-3a4d18ccfff0",        "createdAt": "2019-08-24T14:15:22Z",        "expiresAt": "2019-08-24T14:15:22Z"      }    }  }}