User credentials (v1)

Create a credential

Create a credential. Additional mode-specific parameters apply for JWT, OAUTH, AWS, MTLS, HTTP_REQUEST_AGENT, and MULTI_REQUEST credentials. For a test credential used in TEST mode of change control, provide live_credential_id.

post/api/v1/user_credentials

Request

  • Base URL: https://your-tenant.tines.com
  • URL: https://your-tenant.tines.com/api/v1/user_credentials
  • Auth: one of:
    • API key in header X-User-Token
    • HTTP bearer

Query parameters

include_referencesboolean

Set to true to include IDs of stories and actions referencing this credential (limited to 500 visible actions)

Request body

namestring required

Name of the credential

mode'TEXT' | 'JWT' | 'OAUTH' | 'AWS' | 'MTLS' | 'HTTP_REQUEST_AGENT' | 'MULTI_REQUEST' required

The type of credential

valuestring

Value of the credential (for TEXT credentials)

team_idinteger required

ID of the team where the credential will be located

folder_idinteger

ID of the folder where the credential will be located

read_access'TEAM' | 'GLOBAL' | 'SPECIFIC_TEAMS'

Where this credential can be used (defaults to TEAM). SPECIFIC_TEAMS is a premium feature

shared_team_slugsstring[]

Teams' slugs where this credential can be used. Required to set read_access to SPECIFIC_TEAMS (defaults to [])

descriptionstring

Description of the credential (defaults to "")

metadataobject

Key/value metadata relevant to the credential that can be referenced via the INFO path

allowed_hostsstring[]

Domains where this credential can only be used in HTTP requests. Domain matching supports wildcards

live_credential_idinteger

ID of the live credential that this new test value corresponds to

expires_atstring

When the credential will expire (ISO 8601). Defaults to null

expiry_notifications_enabledboolean

Whether expiry notifications are enabled (defaults to false)

credential_notification_recipient_user_idsinteger[]

User IDs that will be sent credential notifications (e.g. expiry notifications)

Response

Successful response

idinteger

Credential ID

namestring

Name of the credential

modestring

The type of credential (TEXT, JWT, OAUTH, AWS, MTLS, HTTP_REQUEST_AGENT, MULTI_REQUEST)

team_idinteger

ID of team to which the credential belongs

folder_idinteger nullable

ID of folder to which the credential belongs

read_accessstring

Where this credential can be used (TEAM, GLOBAL, SPECIFIC_TEAMS)

shared_team_slugsstring[]

Teams' slugs where this credential can be used when read_access is SPECIFIC_TEAMS, otherwise empty

slugstring

An underscored representation of the credential name

created_atstring

When the credential was created

updated_atstring

When the credential was last updated

descriptionstring

Description of the credential

aws_assumed_role_external_idstring nullable

External ID for AWS assumed role, if any

aws_assumed_role_source_identitystring nullable

Source identity supplied when assuming the AWS role, if any. Requires sts:SetSourceIdentity to be allowed in the role's trust policy, in a separate statement from the one with the sts:ExternalId condition, and, for key-based or instance-profile access, in the calling IAM principal's policy

use_static_external_idboolean

Whether the credential uses a team-scoped static external ID (AWS credentials)

aws_authentication_typestring nullable

The AWS authentication method, if any (KEY, ROLE, INSTANCE_PROFILE)

allowed_hostsstring[]

Domains where this credential can be used in HTTP requests

metadataobject

Key/value metadata for use in HTTP requests alongside the credential value

restriction_typestring

The restriction applied to the credential (RESTRICTED, RESTRICTED_TO_CREDENTIALS, UNRESTRICTED)

test_credential_enabledboolean

Whether the credential is enabled for using a test credential

test_credentialobject nullable

The test credential (created_at, updated_at), present only when test_credential_enabled is true

ownerobject

The user who owns this credential (user_id, first_name, last_name, email)

expires_atstring nullable

When the credential will expire, or null

expiry_notifications_enabledboolean

Whether expiry notifications are enabled

credential_notification_recipient_user_idsinteger[]

User IDs that will be sent credential notifications (e.g. expiry notifications)

referencesobject[]

Stories referencing this credential, grouped by story (story_id, team_id, action_ids). Only included when include_references is true

Changes

No recorded changes to this operation across all 1 revision of this API.