Create a portal
POST
/v1/login-portalsFeatures
Create a login portal for the current team.
Input4
Your API key, sent as
Authorization: Bearer YOUR_SCALAR_ACCESS_TOKEN.Sent from your browser straight to the API — never to Docsbook, never stored.Show child attributes11
Default:
"".Default:
"100".Default:
"Login".Default:
"Click to access private documentation hosted by scalar.com".Default:
"Private Docs".Default:
"#2a2f45".Default:
"#f6f6f6".Default:
"2a2f45".Default:
"#fff".Default:
"#fff".Default:
"#0f0f0f".Show child attributes14
Default:
"Scalar Private Docs".Default:
"Login to access your documentation".Default:
"".Default:
"".Default:
"".Default:
"".Default:
"".Default:
"".Default:
"".Default:
"".Default:
"".Default:
"Scalar Private Docs".Default:
"Login to access your documentation".Default:
"".Output1
Responses
200Default Response
400Bad request
401No auth
403Forbidden
404Not found
422Invalid payload
500Uncaught error
Example input
curl -X POST 'https://access.scalar.com/v1/login-portals' \
-H 'Authorization: Bearer YOUR_SCALAR_ACCESS_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"title": "<title>",
"slug": "<slug>",
"email": {
"logo": "",
"logoSize": "100",
"buttonText": "Login",
"message": "Click to access private documentation hosted by scalar.com",
"title": "Private Docs",
"mainColor": "#2a2f45",
"mainBackground": "#f6f6f6",
"cardColor": "2a2f45",
"cardBackground": "#fff",
"buttonColor": "#fff",
"buttonBackground": "#0f0f0f"
},
"page": {
"title": "Scalar Private Docs",
"description": "Login to access your documentation",
"head": "",
"script": "",
"theme": "",
"companyName": "",
"logo": "",
"logoURL": "",
"favicon": "",
"termsLink": "",
"privacyLink": "",
"formTitle": "Scalar Private Docs",
"formDescription": "Login to access your documentation",
"formImage": ""
}
}'Example output
{
"uid": "<uid>"
}