Ploi API
Ploi API

Create tenant

Adds an tenant to your site

POST api/servers/{server}/sites/{site}/tenants

Parameters

Parameter Type Status Description
tenants array required An array containing all the tenants you want to add

Example request:

curl -X POST "https://ploi.io/api/servers/{server}/sites/{site}/tenants" \
-H "Authorization: Bearer {token}" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
   --data '{"tenants" : ["example.com"]}'

Example response:

HTTP/1.1 200 OK
Content-Type: application/json

{
    "data": {
        "tenants": [
            "anotherdomain.com",
            "example.com"
        ],
        "count": 2,
        "main": "example.com"
    }
}