script templates

Host secret rotation script templates

get/secrets-manager/api/v1/script-templates

List script templates

Get all host secret rotation script templates

OAuth2 oauth

Required Scopes:

adminhostsViewservice

Get all host secret rotation script templates

All Scopes

  • admin · Admin scope - used for built-in PrivX admin account
  • hostsManage · User with "hosts-manage" permission
  • hostsProvisioning · Deploy script client scope
  • hostsView · User with "hosts-view" permission
  • service · Microservice scope - used for communication between PrivX microservices
  • targetDomainsManage · User with "target-domains-manage" permission
  • targetDomainsView · User with "target-domains-view" permission
  • user · Normal user

Responses

Response examples

script template response

{
  "count": 123,
  "items": [
    {
      "id": "5bf77342-221c-11ee-be56-0242ac120002",
      "name": "string",
      "operating_system": "LINUX",
      "script": "string",
      "created": "2017-01-01T15:05:05Z",
      "updated": "2017-01-01T15:05:05Z",
      "created_by": "string",
      "updated_by": "string"
    }
  ]
}
post/secrets-manager/api/v1/script-template

Create a script template

Create a host secret rotation script template

namestring
scriptstring

Responses

Request examples

{
  "name": "string",
  "script": "string"
}

Response examples

inserted

{
  "id": "5bf77342-221c-11ee-be56-0242ac120002"
}
get/secrets-manager/api/v1/script-template/{id}

Get a script template

Get a host secret rotation script template by ID

idstring

required

Responses

Response examples

scripts array

{
  "id": "5bf77342-221c-11ee-be56-0242ac120002",
  "name": "string",
  "operating_system": "LINUX",
  "script": "string",
  "created": "2017-01-01T15:05:05Z",
  "updated": "2017-01-01T15:05:05Z",
  "created_by": "string",
  "updated_by": "string"
}
put/secrets-manager/api/v1/script-template/{id}

Update a script template

Update a host secret rotation script template by ID

idstring
Format
uuid
namestring
operating_systemstring

powershell for windows and Unix Shell for Linux

Enum
  • LINUX
  • WINDOWS
scriptstring

script as string

createdstring

When the object was created. Added by backend

Format
date-time
Example
"2017-01-01T15:05:05Z"
updatedstring

When the object was updated. Added by backend

Format
date-time
Example
"2017-01-01T15:05:05Z"
created_bystring

added by backend

updated_bystring

added by backend

Responses

Request examples

{
  "id": "5bf77342-221c-11ee-be56-0242ac120002",
  "name": "string",
  "operating_system": "LINUX",
  "script": "string",
  "created": "2017-01-01T15:05:05Z",
  "updated": "2017-01-01T15:05:05Z",
  "created_by": "string",
  "updated_by": "string"
}

Response examples

inserted

{
  "id": "5bf77342-221c-11ee-be56-0242ac120002",
  "name": "string",
  "operating_system": "LINUX",
  "script": "string",
  "created": "2017-01-01T15:05:05Z",
  "updated": "2017-01-01T15:05:05Z",
  "created_by": "string",
  "updated_by": "string"
}
delete/secrets-manager/api/v1/script-template/{id}

Delete a script template

Delete a host secret rotation script template by ID

idstring

required

Responses

Response examples

deleted

Empty response

post/secrets-manager/api/v1/script-template/compile

Compile a script template

Compile a script template with test data

operating_systemstring
Enum
  • LINUX
  • WINDOWS
scriptstring

Responses

Request examples

{
  "operating_system": "LINUX",
  "script": "string"
}

Response examples

example script

{
  "script": "string"
}

Was this page helpful?