Open API : How to specify team when creating a new site

Hi all. I’m trying to use the Open API to create a new site on a specific team on which I’m a member. I’ve specified the account_name and account_slug params of the request body and for some reason that doesn’t seem to do the trick. e.g.:

// request
{
    // ... more settings
    "account_name": "Minimart",
    "account_slug" : "resto-minimart"
}

the response payload, however, always defaults to my other team:

// response
{
    // ... other stuff
    "account_slug": "resto",
    "account_name": "Resto",     
    // ... other stuff
}

Any guidance around this would be helpful. I’ve consulted the Open API docs and can’t figure out how to pass the correct data to assign it to a different team.

Thanks :+1:

Hey @Resto,
Sorry for the slow response here and thanks for your patience! You should be able to use https://open-api.netlify.com/#operation/createSiteInTeam to do this. Please let us know if that doesn’t work for you!

1 Like

Ah, perfect. Thanks!

1 Like