ModernLoop Internal API
Apipylon

Create a Pylon contact (POST /contacts)

Write operation: mutates state in the upstream service.

curl -X POST "https://api.modernloop.dev/rest/v1/pylon/contacts" \  -H "Authorization: Bearer $MLOOP_INTERNAL_MCP_API_KEY" \  -H "Content-Type: application/json" \  -d '{    "name": "string"  }'
{  "data": {    "id": "string",    "name": "string",    "email": "string",    "emails": [      "string"    ],    "avatar_url": "string",    "phone_numbers": [      "string"    ],    "primary_phone_number": "string",    "portal_role": "no_access",    "portal_role_id": "string",    "account": {      "id": "string",      "external_ids": [        {          "external_id": "string",          "label": "string"        }      ]    },    "external_ids": [      {        "external_id": "string",        "label": "string"      }    ],    "integration_user_ids": [      {        "id": "string",        "source": "string"      }    ],    "custom_fields": {      "property1": {        "slug": "string",        "value": "string",        "values": [          "string"        ]      },      "property2": {        "slug": "string",        "value": "string",        "values": [          "string"        ]      }    }  },  "request_id": "string"}
{  "error": {    "code": "string",    "message": "string",    "upstreamStatus": 0  }}
{  "error": {    "code": "string",    "message": "string",    "upstreamStatus": 0  }}
{  "error": {    "code": "string",    "message": "string",    "upstreamStatus": 0  }}
{  "error": {    "code": "string",    "message": "string",    "upstreamStatus": 0  }}

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

name*string
Length1 <= length
email?string
account_id?string
account_external_id?string
avatar_url?string
phone_numbers?array<string>
primary_phone_number?string
portal_role?string

Value in

  • "no_access"
  • "member"
  • "admin"
portal_role_id?string
external_ids?array<>
custom_fields?array<>

Response Body

application/json

application/json

application/json

application/json

application/json