POST Flow/Tickets/Approve

Adds an approval to a pending FlowTicket. If this meets the required number of approvals, the status of the FlowTicket is updated to Approved. You can only approve Flow Tickets that have a status of Pending. For example, if someone requests to join a team, the ticket moves to a Pending state for approval or rejection. For more information, see Flow Ticket status codes.

NOTE  If you are using this API call to join a person or group to a Team, the requester receives a email confirmation. The email includes Comment and other information.

For CodeSign Protect, if you want to expedite an approval, call POST Codesign/AddPreApproval.

Requirements

  • The caller must be a Flow Ticket approver of the resource. For Team flow approvals, the caller must be the team owner.
  • Token scope:  Any valid scope, such as Agent, Certificate, or SSH:Approve

Headers

  • Content type: Content-Type:application/json.

  • Token: The bearer access token that you received. For example, Authorization:Bearer 4MyGeneratedBearerTknz==. For more information, see Passing a bearer token in your API calls.

Parameters

Specify TicketId or the TicketIDs array, not both.

Input parameters

Name

Description

Expires

(Optional)The maximum duration the ticket may be used before a new ticket is required. Specify the Universal Time Coordinated (UTC), for example YYYY-MM-DDTHH:MM:SS.mmm.

Comment (Optional)Additional information.

notBefore

(Optional) Case sensitive. The earliest time the ticket may be approved. Specify the Coordinated Universal Time (UTC), for example YYYY-MM-DDTHH:MM:SS.mmm.

TicketId

Case sensitive. A Flow Ticket Id that is Pending review for approval or rejection. Carefully review and use an Id from POST Flow/Tickets/Enumerate.

TicketIDs

Case sensitive. An array of Flow Ticket Ids that are Pending review for approval or rejection. Carefully review and use Ids from POST Flow/Tickets/Enumerate.

useCount (Optional) Case sensitive. The maximum number of times the ticket may be used before a new ticket is required. Default is null to allow an unlimited number of times the ticket can be reused.

Returns

Valid requests return an HTTP 200. Request with errors return one of the following:

Response description

Name

Description

Error

The reason the HTTP 400 Bad Request occurred.

Result

The Result code of this API call. For more information, see Flow Ticket result codes.

Message

Appears only if Result is a non-zero value.

Example: Approve a pending Flow Ticket

Request

POST https://tpp.venafi.example/vedsdk/Flow/Tickets/Approve
Authorization:Bearer 4MyGeneratedBearerTknz==
{
   "TicketIDs":[
      12,
      14,
      47
   ],
   "useCount" : 1,
   "notBefore": "2020-06-05 23:59:59.000",
   "comment": "You are now a member of this team"
}

Response

HTTP/1.1 200 OK
{
}