Jump to: navigation, search

Complete Service

ApiRef2.png
POST /services/${service_id}/end

Description

Terminates the given service. Your application can update service information in the body of this operation. In 8.0.2, your application can specify values for extensions (single-valued and multi-valued). If your application already recorded a value or a set of values for a given extension, the previous record is replaced with the new one.

Operation

Complete a Service
ID CV.WS.SRV.3
Method POST
URL /services/${service_id}/end
Field Name   Type   Mandatory Description
URI Parameter
${service_id} integer yes In the request URI, the unique ID of the service.
Body: Service End Event<ref>The body of this operation corresponds to the Service End Event resource.</ref>
session_id string no The ID of the related session (for instance, the orchestration session or any other business session). Limited to 32 characters.
interaction_id string no The ID of the interaction at the service event's creation. Limited to 50 characters.
application_type long or string no The unique ID associated with the type or class<ref name="business">

Refer to Configuration Options for more details on Business Attribute mapping.</ref> of application which issued the service event. May be used to group related applications, potentially across resource types.

application_id integer no The Genesys DB ID for the application which issues the service event, such as a GVP VoiceXML application, Orchestration SCXML application, etc.
resource_type long or string no The unique ID associated with the type or class<ref name="business"/> of resource providing the service (e.g. GVP, Agent Desktop, Orchestration).
resource_id integer no The unique DB ID for the specific resource which provides the service. For instance:
  • The Genesys DB ID of a specific GVP or orchestration platform
  • The DB ID of a given agent, according to the context.
media_type long or string no The media type<ref name="business"/> applicable to the given service, such as e-mail, voice, chat, etc.
disposition long or string no The unique ID for the business disposition<ref name="business"/> assigned to the given service. For instance, this can be the DB ID of a Business Attribute used to enumerate a given organization’s business dispositions.
disposition_desc string no The text description which provides additional context on the business disposition. Limited to 64 characters.
timestamp date/time no The UTC time at which the service event was raised, with a precision of milliseconds, using the ISO 8601<ref name="iso8601">See http://en.wikipedia.org/wiki/ISO_8601</ref> representation : [YYYY]-[MM]-[DD]T[HH]:[mm]:[ss].[SSS]Z.
Information.png If the application does not specify this timestamp, the server adds it when the service event is processed.
<extension n>
Supported since 8.0.2
Extension (single-valued)
or Extension[] (multi-valued)
no Service extensions, where <extension n> corresponds to the unique name of the service extension. Your application can specify as many extensions as needed as long as you defined their schemas with the CreateServiceExtensionSchema operation.

<references />

Response

The Context Management Service API answers with HTTP codes for every request. The following table shows the correct response for a successful request. See HTTPResponseCodesandErrors for further details on the possible codes that this operation can return.

Response
HTTP code 204
HTTP Title No Content

Example

Operation

POST /services/36981723/end
{
  "timestamp": "2009-05-12T12:05:12.145Z",
  "interaction_id": "123ABCAADFJ1259ACF",
  "media_type": 1,
  "resource_id": 5005,
  "resource_type": 2,
  "disposition": 10,
  "disposition_desc": "SUCCESS"
  "Feedback": 
   { 
       "FeedbackType":"survey",
       "rating":7,
       "notes":"warm welcome at frontdesk, thanks for the nice trip"
   },
   "Satisfaction": [
   {
       "rating":2,
       "pertinence":8,
       "usefull":true,
       "place":"Terranova mexico resort"
   },
   {
       "rating":8,
       "pertinence":4,
       "usefull":false,
       "place":"Fancy resort Paris"
   }
 ]
}

Result

204 No Content
This page was last edited on November 23, 2017, at 16:00.
Comments or questions about this documentation? Contact us for support!