Start of change

Add an approval for a software services template

You can use this operation to create an approval record for a software services template. The approval record associates a user ID with the software services template.

HTTP method and URI path

POST /zosmf/provisioning/rest/<version>/scc/<object-id>/approvals
In this request
<object-id>
Identifies the software services template that the approval is associated with.
<version>
Is the URI path variable <version> that identifies the version of the z/OSMF software services template service. The following value is valid: 1.0.

Query parameters

None.

Description

This operation lets you create a new general approval record for a software services template. It returns a unique approval object ID that identifies the approval. The approval is for all of the contents of the software services template and is not associated with a specific step or action.

The software services template must be in one of the draft states.

All approvals for a software services template must be approved before it can be published or tested. Once all the approvals are approved the state of the entry is updated to draft_approved.

On successful completion, HTTP status code 201 (Normal) is returned, indicating that the approval was created.

Request content

The request content is expected to contain a JSON object that describes the approval record. See Request content for the software services template request.

Table 1. Request content for the add approval request
Field name Type Required or optional Description
user-id String Required User ID associated with this approval.

Authorization requirements

The user's z/OS user ID must be defined as a landlord or a domain administrator.

The user’s z/OS user ID must have READ access to the following resource profile in the ZMFAPLA class: <SAF-prefix>.ZOSMF.PROVISIONING.SOFTWARE_SERVICES.

For more information, see Authorization requirements.

HTTP status codes

On successful completion, HTTP status code 201 (Normal) is returned.

Response content

On successful completion, the service returns a response body, which contains a JSON object with details about the software services template request. Table 1 lists the fields in the JSON object.

Table 2. Response from an add approval request
Field Type Description
object-id String Object ID of the newly created approval. The object ID is to be used in subsequent requests to the session.
object-uri String URI of the newly created approval.

Example HTTP interaction

In Figure 1, a request is submitted to add an approval record for a software services template.
Figure 1. Sample request to add an approval record for a software services template
POST https://localhost:4444/zosmf/provisioning/rest/1.0/scc/8abd70b5-ac74-4f4a-bc09-266bf7cf8270/approvals

{     
    "user-id":"nick"
}

The following is the response body for the request.

Figure 2. Sample response body
{   
    "object-id": "eeb4f5a3-d883-4190-9961-412306707426",
    "object-uri": "/zosmf/provisioning/rest/1.0/scc/8abd70b5-ac74-4f4a-bc09-266bf7cf8270/
     approvals/eeb4f5a3-d883-4190-9961-412306707426"
}

End of change