Skip to content

Create a Preauthorization

Request

Admin roles:
  • access_admin

Creates a Preauthorization for a Project. A Preauthorization is a time-limited grant for a User to access resources in a specific Project.

Security
bearerAuth
Path
team_namestringrequired

The name of your Team

project_namestringrequired

The Project name

Bodyapplication/jsonrequired
disabledbooleanrequired

Indicates the status of the Preauthorization. If true, the Preauthorization is disabled.

expires_atstring, (date-time)required

A timestamp indicating when the Preauthorization expires

projectsArray of stringsrequired

The Project associated with the Preauthorization

serversArray of strings or null

The Servers accessed using the Preauthorization

user_namestring, [ 1 .. 255 ] charactersrequired

The User associated with the Preauthorization

curl -i -X POST \
  'https://app.scaleft.com/v1/teams/{team_name}/projects/{project_name}/preauthorizations' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "disabled": false,
    "expires_at": "2020-07-28T18:30:00Z",
    "id": "",
    "projects": [
      "the-sound-and-the-fury"
    ],
    "servers": null,
    "user_name": "jason.compson"
  }'

Responses

Created