Overview

Create a portal

POST/v1/login-portals
Features

Create a login portal for the current team.

Input4
Authorizationheaderrequired
Your API key, sent as Authorization: Bearer YOUR_SCALAR_ACCESS_TOKEN.Sent from your browser straight to the API — never to Docsbook, never stored.
titlestring · bodyrequired
slugstring · bodyrequired
emailobject · bodyrequired
Show child attributes11
logostringrequired
Default: "".
logoSizestringrequired
Default: "100".
buttonTextstringrequired
Default: "Login".
messagestringrequired
Default: "Click to access private documentation hosted by scalar.com".
titlestringrequired
Default: "Private Docs".
mainColorstringrequired
Default: "#2a2f45".
mainBackgroundstringrequired
Default: "#f6f6f6".
cardColorstringrequired
Default: "2a2f45".
cardBackgroundstringrequired
Default: "#fff".
buttonColorstringrequired
Default: "#fff".
buttonBackgroundstringrequired
Default: "#0f0f0f".
pageobject · bodyrequired
Show child attributes14
titlestringrequired
Default: "Scalar Private Docs".
descriptionstringrequired
Default: "Login to access your documentation".
headstringrequired
Default: "".
scriptstringrequired
Default: "".
themestringrequired
Default: "".
companyNamestringrequired
Default: "".
logostringrequired
Default: "".
logoURLstringrequired
Default: "".
faviconstringrequired
Default: "".
termsLinkstringrequired
Default: "".
privacyLinkstringrequired
Default: "".
formTitlestringrequired
Default: "Scalar Private Docs".
formDescriptionstringrequired
Default: "Login to access your documentation".
formImagestringrequired
Default: "".
Output1
uidstring
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>"
}

Updated

Was this page helpful?