SCP Messages

Introduction

The Logic Hand-Off SCP Application (LhoScpApp) uses SCP-... messages to instance to hand-off external call control of SCP processing. These messages are transmitted over the n2svcd message bus between the Logic Hand-Off SCP Application (LhoScpApp) and the Logic Application (LogicApp).

All calls in the SCP processing model are “inbound” calls, which are initiated by an InitialDP operation which is initially received by the SigtranApp, which delivers it to the the LhoScpApp, which then sends SCP-HANDLE-ALEG-IDP message to the LogicApp.

So in summary:

  1. The SigtranApp handles the SCTP SIGTRAN connections and sends/receives TCAP-... messages.
  2. The LhoScpApp sends/receives TCAP-... messages, and sends/receives SCP-... messages.
  3. The LogicApp sends/receives SCP-... messages, and executes the LUA script logic.

For load-sharing purposes when executing on a multi-core environment, both the LhoScpApp and LogicApp applications are typically multiple process applications using the repeat parameter. The SigtranApp cannot be repeated because only one process may own the SCTP connection for each SCTP port number.

The SCP-... message names are divided into two categories depending on which direction the message is flowing.

a. SCP-HANDLE-... messages from LhoScpApp to LogicApp to request service logic assistance.
b. SCP-DO-... messages from LogicApp to LhoScpApp to perform service logic actions.

SCP Example Message Flow

Here is an example SIGTRAN and n2svcd message flow for a CAMEL2+ charged call (INAP Connect with no CallInformationReport) with a pre-call on-switch announcement, a single sucessful charge extension, a B-Party disconnect, and a final ReleaseCall.

Interaction with the Online Charging Server is implied but not shown.

SCP Message Flow (Out-Call)

SCP-DO-INAP-ALEG-INTERACTION

The SCP-DO-INAP-ALEG-INTERACTION is sent by the LogicApp to the LhoScpApp to request that the call perform user interaction via an on-switch ConnectToResource SRP or an external EstablishTemporaryConnect SRP.

The service logic must specify the name of the SRP to use, which must be a configured SRP in the LhoScpApplication.

If a different SRP is currently open then a prior DisconnectForwardConnection will first be sent on the previous SSP transaction, and any external SRP transaction will be ended according to the applicable SRP configuration.

After sending this message, the service logic should send no further messages until it receives one of the following messages from the LhoScpApp:

The attributes of the SCP-DO-INAP-ALEG-INTERACTION message are:

Field Type Description
scp Object [Required] The SCP control parameters for the message.
.srp_name String [Required] The SRP name as configured in the LhoScpApp.
.message_id Integer A single message ID to play. This ID must be coordiated with the SRP node that is playing the announcement.
Specify exactly one of .message_id or .message_ids.
.message_ids Array of Integer An array of message IDs to play. These IDs must be coordiated with the SRP node that is playing the announcement.
Specify exactly one of .message_id or .message_ids.
Playing of multiple message IDs is not compatible with `.variables`.
.language String Specifies an SRP language name as configured in the LhoScpApp.
This will be mapped to the associated numeric ID and sent to the SRP using the associated mechanism.
The language is used to select the preferred audio file, and to encode variable parts such as numbers and dates.
(Default = do not pass language to the SRP).
.repetition Integer Sets the `informationToSend.inbandInfo.numberOfRepetitions` sent to the SRP.
Interpretation of this value is specific to the SRP.
(Default = do not specifiy this value to the SRP).
.duration Integer Sets the `informationToSend.inbandInfo.duration` sent to the SRP.
Interpretation of this value is specific to the SRP.
(Default = do not specifiy this value to the SRP).
.interval Integer Sets the `informationToSend.inbandInfo.interval` sent to the SRP.
Interpretation of this value is specific to the SRP.
(Default = do not specifiy this value to the SRP).
.variables Array of Object Each variable part Object must specify exactly one of the indicated options.
Some SRPS may place a limit in the number of variable parts.
(Default = do not supply variable parts to the SRP).
.integer Positive Integer Indicates that the variable part should be "spoken" as an natural language integer by the SRP.
The SRP may place an upper bound on the supported integer range. Negative numbers are not supported.
The natural algorithm will use the preferred, or the default language.
.number_digits Digit String Indicates that the variable part should be "spoken" as a natural language digit string by the SRP.
The SRP may limit the characters supported in this string. Typically [0-9][A-F] and "*" and "#" are supported.
The natural algorithm will use the preferred, or the default language.
.date_yymmdd String Indicates that the variable part should be "spoken" as a natural language date string by the SRP.
The string is "YYMMDD" six-digits. The handling of century is SRP-dependent.
The natural algorithm will use the preferred, or the default language.
.time_hhmm String Indicates that the variable part should be "spoken" as a natural language time string by the SRP.
The string is "HHMM" four-digits. The handling of am/pm, noon, and midnight is SRP-dependent.
The natural algorithm will use the preferred, or the default language.
.price_digits String Indicates that the variable part should be "spoken" as a natural language decimal price string by the SRP.
The string is "[DDDDDD]CC" from two to eight digits. The handling of zero cents is SRP-dependent.
The natural algorithm will use the preferred, or the default language.
.prompt 1 Set this field to 1 if you wish the interaction to collect user input digits.
(Default = do not collect user input digits).
.min_num_digits 1 - 32 The minimum number of digits which the SRP will be instructed to collect.
This field is relevant only when prompt is specified.
[Required] This required when prompt is specified.
.max_num_digits 1 - 32 The maximum number of digits which the SRP will be instructed to collect.
This value must be greater than or equal to min_num_digits.
This field is relevant only when prompt is specified.
[Required] This required when prompt is specified.
.first_digit_timeout Positive Integer The number of seconds allowed between completing the announcement and entering the first digit.
This field is relevant only when prompt is specified.
(Default = determined by the SRP).
.inter_digit_timeout Positive Integer The number of seconds allowed between entering one digit and entering the subsequent digit.
This field is relevant only when prompt is specified.
(Default = determined by the SRP).
.end_digit #*A-F0-9 The digit which specifies End of Input.
This field is relevant only when prompt is specified.
(Default = determined by the SRP).
.cancel_digit #*A-F0-9 The digit which specifies Cancel Input.
This field is relevant only when prompt is specified.
(Default = determined by the SRP).
.interruptable 0 / 1 Informs the SRP that the prompt should be interrupted by user input.
This field is relevant only when prompt is specified.
(Default = the prompt may be interrupted by the user).

SCP-DO-INAP-BLEG-TERMINATION-FINAL

The SCP-DO-INAP-BLEG-TERMINATION-FINAL is sent by the LogicApp to the LhoScpApp to request that a B-Leg be set-up by sending INAP Continue or INAP Connect on the SSP transaction, with an optional FurnishChargingInformation.

There will be no RequestReportBCSM and no CallInformationRequest.

If an SRP is currently open then a prior DisconnectForwardConnection will be sent on the SSP transaction, and any external SRP transaction will be ended according to the applicable SRP configuration.

No further SCP-... messages should be exchanged after this message is sent.

The attributes of the SCP-DO-INAP-BLEG-TERMINATION-FINAL message are:

Field Type Description
scp Object [Required] The SCP control parameters for the message.
.fci String Specify the content of the FCIBillingChargingCharacteristics in the FurnishChargingInformation to send.
(Default = do not send FurnishChargingInformation).
.address_digits Digit String Specify the normalised destinationRoutingAddress digits (only 0-9A-F).
The applicable configured 'called_party' denormalisation on the LhoScpApp will be applied.
If this field is present, then INAP Connect will be used, else INAP Continue is sent.
.orig_called_digits Digit String This field is only relevant when address_digits is specified.
Specify the normalised destinationRoutingAddress digits (only 0-9A-F).
The applicable configured 'calling_party' denormalisation on the LhoScpApp will be applied.
(Default = not present).
.redirecting_digits Digit String This field is only relevant when address_digits is specified.
Specify the normalised redirectingPartyID digits (only 0-9A-F).
The applicable configured 'calling_party' denormalisation on the LhoScpApp will be applied.
(Default = not present).
.redirection_info Object This field is only relevant when address_digits is specified.
(Default = not present).
.orig_reason 0 - 15 Specify an explicit redirection information original reason.
(Default = 0).
.indicator 0 - 7 Specify an explicit redirection information indicator.
(Default = 0).
.reason 0 - 15 Specify an explicit redirection information reason.
(Default = 0).
.national_use 0 / 1 Specify an explicit redirection information national use value.
(Default = 0).
.counter 0 - 7 Specify an explicit redirection information counter.
(Default = 1).

SCP-DO-INAP-BLEG-TERMINATION-ATTEMPT

The SCP-DO-INAP-BLEG-TERMINATION-ATTEMPT is sent by the LogicApp to the LhoScpApp to request that a B-Leg B-Leg be set-up by sending INAP Continue or INAP Connect on the SSP transaction, with an optional FurnishChargingInformation.

A RequestReportBCSMEvent will be sent to arm for the Answer, NoAnswer, Busy, RouteSelectFailure, and Abandon event detection points. The Disconnect EDPs are not armed.

There will be no CallInformationRequest.

If an SRP is currently open then a prior DisconnectForwardConnection will be sent on the SSP transaction, and any external SRP transaction will be ended according to the applicable SRP configuration.

After sending this message, the service logic should send no further messages until it receives one of the following messages from the LhoScpApp:

The attributes of the SCP-DO-INAP-BLEG-TERMINATION-ATTEMPT message are:

Field Type Description
scp Object [Required] The SCP control parameters for the message.
.no_answer_timeout Integer Specify the value to send in the dPSpecificCriteria.applicationTimer.
For CAMEL1 MSCs this value is used for an internal SCP NoAnswer timer.
This value must not exceed the configured possible maximum value for the SSP model.
(Default = use the default configured for the SSP model, if any).
.fci String Specify the content of the FCIBillingChargingCharacteristics in the FurnishChargingInformation to send.
(Default = do not send FurnishChargingInformation).
.address_digits Digit String Specify the normalised destinationRoutingAddress digits (only 0-9A-F).
The applicable configured 'called_party' denormalisation on the LhoScpApp will be applied.
If this field is present, then INAP Connect will be used, else INAP Continue is sent.
.orig_called_digits Digit String This field is only relevant when address_digits is specified.
Specify the normalised destinationRoutingAddress digits (only 0-9A-F).
The applicable configured 'calling_party' denormalisation on the LhoScpApp will be applied.
(Default = not present).
.redirecting_digits Digit String This field is only relevant when address_digits is specified.
Specify the normalised redirectingPartyID digits (only 0-9A-F).
The applicable configured 'calling_party' denormalisation on the LhoScpApp will be applied.
(Default = not present).
.redirection_info Object This field is only relevant when address_digits is specified.
(Default = not present).
.orig_reason 0 - 15 Specify an explicit redirection information original reason.
(Default = 0).
.indicator 0 - 7 Specify an explicit redirection information indicator.
(Default = 0).
.reason 0 - 15 Specify an explicit redirection information reason.
(Default = 0).
.national_use 0 / 1 Specify an explicit redirection information national use value.
(Default = 0).
.counter 0 - 7 Specify an explicit redirection information counter.
(Default = 1).

SCP-DO-INAP-RELEASE-CALL-FINAL

The SCP-DO-INAP-RELEASE-CALL-FINAL is sent by the LogicApp to the LhoScpApp to request that the call be ended by sending INAP ReleaseCall on the SSP transaction.

If an SRP is currently open then a prior DisconnectForwardConnection will be sent on the SSP transaction, and any external SRP transaction will be ended according to the applicable SRP configuration.

No further SCP-... messages should be exchanged after this message is sent.

The attributes of the SCP-DO-INAP-RELEASE-CALL-FINAL message are:

Field Type Description
scp Object [Required] The SCP control parameters for the message.
.cause 0 - 127 Specify an explicit release cause.
(Default = as configured in LhoScpApp).

SCP-DO-SHUTDOWN

The SCP-DO-SHUTDOWN is sent by the LogicApp to the LhoScpApp to indicate that service logic processing has failed unexpectedly and cannot continue. The LhoScpApp will perform any necessary TCAP transaction closure, typically using TCAP_ABORT. The LhoScpApp will raise a warning, in addition to the service logic warning which usually arises.

No further SCP-... messages should be exchanged after this message is sent.

The attributes of the SCP-DO-SHUTDOWN message are:

Field Type Description
success 0 [Required] Indicator that the logic was not successful.
error String [Required] A descriptive error message to record in the warning.

SCP-DO-TCAP-SSP-ABORT-FINAL

The SCP-DO-TCAP-SSP-ABORT-FINAL is sent by the LogicApp to the LhoScpApp to request that the call be deliberately ended using TCAP_ABORT on the SSP transaction. Any open external SRP transction will also be ended according to the applicable SRP configuration.

No further SCP-... messages should be exchanged after this message is sent.

The attributes of the SCP-DO-TCAP-SSP-ABORT-FINAL message are:

Field Type Description
scp Object [Required] The SCP control parameters for the message.
.u_information0 String Specify an explicit string for the TCAP_ABORT u_information array element.

SCP-HANDLE-ALEG-IDP

The SCP-HANDLE-ALEG-IDP message is sent from the LhoScpApp to the LogicApp as the first message in all Logic Hand-Off SCP calls. It occurs when the INAP/CAMEL InitialDP is received. The LhoScpApp is configured with the name of the LogicApp to which it should send the SCP-HANDLE-ALEG-IDP.

When the SCP-HANDLE-ALEG-IDP arrives at the LogicApp, there must be a configured LhoScpLuaService present to receive and process it. The LhoScpLuaService will examine the request contents and compare that to its configured triggers list (or database equivalent) in order to determine which LUA script to execute.

The actual logic for selecting and loading the LUA script depends on the specific service. The matching and loading will typically come from a database, e.g. for the N2ACD-SCP implementation for Toll-Free SCP call handling.

After receiving SCP-HANDLE-ALEG-IDP, the call is “controlled” by the service logic.
The service logic must (within the service logic timer) send one of the following SCP control messages:

The attributes of the SCP-HANDLE-ALEG-IDP message are:

Field Type Description
scp Object [Required] The SCP control parameters for the message.
.ssp_inap String [Required] INAP/CAMEL variant.
The name of the INAP/CAMEL variant for the selected SSP Model handling this call.
E.g. camel2. See the list of supported INAP/CAMEL variants.
.supported Object [Required] Container for supported feature flags.
.release_tone 0 / 1 [Required] Does the SSP Model support setting of `release_tone`.
If this flag is not = 1 then service logic attempts to set `release_tone` in charged call terminations or extensions will result in call-processing failure.
.fci 0 / 1 [Required] Does the SSP Model support sending of FCI information.
If this flag is not = 1 then service logic attempts to send FCI content in call terminations will result in call-processing failure.
.interaction 0 / 1 [Required] Does the SSP Model support use of interaction using PlayAnnouncement or PromptAndCollectUserInformation.
If this flag is not = 1 then service logic attempts to perform interaction during the call control will result in call-processing failure.
.call_information 0 - 31 [Required] Which information does the SSP Model support reporting via CallInformationReport (CIR).
Bitmask:
  • 1 = call attempt elapsed time (CAET); "ring time"
  • 2 = call stop time (CST)
  • 4 = call connected elapsed time (CCET); "talk time"
  • 8 = called address
  • 16 = release cause
If this field value = 0 then service logic attempts to use CIR features in call terminations or extensions will result in call-processing failure.
.activity_test 0 / 1 [Required] Does the SSP Model support the use of gap-filling ActivityTest.
If this flag is not = 1 then service logic attempts to enable gap-filling ActivityTest in call terminations or extensions will result in call-processing failure.
.max_charged_call_secs Integer This is the maximum number of talk-time seconds which the SSP protocol can support for a charged call.
The service logic must never grant a total talk-time greater than this value.
For most CAMEL protocols this is typically 86400 but it may be configured lower than this value on a per-SSP basis.
.remote_sccp Object [Required] The address of the SCCP node that triggered the call to us.
.ri 0 / 1 [Required] Routing Indicator.
1 = route on PC + SSN, 0 = Route on GT)
.pc Integer Point Code.
This field is present if and only if the address specifies a point code.
.ssn Integer Sub-System Number.
This field is present if and only if the address specifies a sub-system number.
.gt_digits Hex Digits Hex Digits for Global Title address.
This field is present if and only if the address specifies a global title.
.gt_noa Integer Global Title Nature of Address (0-127).
This field is present if and only if the address specifies a global title. (Default = 0)
.gt_np Integer Global Title Numbering Plan (0-7).
This field is present if and only if the address specifies a global title. (Default = 1, E.164)
.gt_tt Integer Global Title Translation Type (0-255).
This field is present if and only if the address specifies a global title.
.call_trigger ORIG / TERM / FWD [Required] Indicator of the call trigger.
This distinguishes between originating, terminating, and forwarded call triggers.
.normalised_calling_party Digit String [Required] (Normalised) Calling Party Number address digits.
This is the calling party address digits after any configured 'calling_party' normalisation rules have been applied.
It is determined from the callingPartyNumber element of the InitialDP.
It is guaranteed to contain only 0-9A-F digits.
.normalised_called_party Digit String [Required] (Normalised) Called Party (BCD) Number address digits.
This is the called party address digits after any configured 'called_party' or 'called_party_bcd' normalisation rules have been applied.
It is determined from the calledPartyBCDNumber or calledPartyNumber element of the InitialDP.
It is guaranteed to contain only 0-9A-F digits.
.normalised_redirecting_party Digit String (Normalised) Redirecting Party ID address digits.
This is the redirecting party address digits after any configured 'calling_party' normalisation rules have been applied.
It is determined from the redirectingPartyID element of the InitialDP, if present.
It is guaranteed to contain only 0-9A-F digits.
.normalised_original_called_party Digit String (Normalised) Original Called Party address digits.
This is the original called party address digits after any configured 'called_party' normalisation rules have been applied.
It is determined from the originalCalledPartyID element of the InitialDP, if present.
It is guaranteed to contain only 0-9A-F digits.
.forwarding_pending 1 This field is present and 1 if and only if the gsm-ForwardingPending or callForwardingSS-Pending element is present in the InitialDP.
.initialdp_arg Object [Required] Complete decoded InitialDP structure.
.idp_key String [Required] A pseudo-unique identifier for the call.
One of:
  • [call_trigger]:[MSC address digits]:[call reference number]
  • [call_trigger]:[normalised_calling_party]:[normalised_called_party]

SCP-HANDLE-ALEG-INTERACTION-COMPLETE-ONGOING

The SCP-HANDLE-ALEG-INTERACTION-COMPLETE-ONGOING message is sent from the LhoScpApp to the LogicApp as a response to SCP-DO-INAP-ALEG-INTERACTION if the interaction completes with the A-Leg still active.

After receiving SCP-HANDLE-ALEG-INTERACTION-COMPLETE-ONGOING, the call is still “controlled” by the service logic. The service logic must (within the service logic timer) send one of the following SCP control messages:

The attributes of the SCP-HANDLE-ALEG-INTERACTION-COMPLETE-ONGOING message are:

Field Type Description
scp Object [Required] The SCP control parameters for the message.
.error String Note that .error and .digits are mutually exclusive.
This field is present if and only if the SRP indicated a problem playing the announcement. This could relate to the message ID not being known on the platform, or could indicate a problem with the language or the variable parts not being supported.
When prompting for digits input, this field is present if the SRP could not collect sufficient digits prior to reaching the digit entry timeout limit.
When present, the service logic should assume that the user did not successfully interact with the SRP.
Interrupting an interruptable announcement does not cause this field to be set.
.digits #*A-F0-9 Note that .error and .digits are mutually exclusive.
This field contains the digits successfully retrieved by the user during the interaction.
In theory, the SRP should return no digits at all in the case where insufficient digits are entered. However, that behavior can vary according to SRP manufacturer, and the service logic should always validate the number of digits returned.

SCP-HANDLE-ALEG-INTERACTION-ABANDONED-FINAL

The SCP-HANDLE-ALEG-INTERACTION-ABANDONED-FINAL message is sent from the LhoScpApp to the LogicApp as a response to SCP-DO-INAP-ALEG-INTERACTION if the interaction completes with the A-Leg no longer active.

After receiving SCP-HANDLE-ALEG-TEARDOWN-FINAL, the call is no longer “controlled” by the service logic.

No further SCP-... messages should be exchanged after this message is sent.

The attributes of the SCP-HANDLE-ALEG-INTERACTION-ABANDONED-FINAL message are:

Field Type Description
scp Object [Required] The SCP control parameters for the message.
.reason String [Required] A brief description of the reason for the abandonment of the session.
This string is useful for debugging SRP behavior but is not generally relevant to the service logic.
.error String Note that .error and .digits are mutually exclusive.
Note that .error may be present even when .reason is present.
This field is present if and only if the SRP indicated a problem playing the announcement. This could relate to the message ID not being known on the platform, or could indicate a problem with the language or the variable parts not being supported.
When prompting for digits input, this field is present if the SRP could not collect sufficient digits prior to reaching the digit entry timeout limit.
When present, the service logic should assume that the user did not successfully interact with the SRP.
Interrupting an interruptable announcement does not cause this field to be set.
.digits #*A-F0-9 Note that .error and .digits are mutually exclusive.
This field contains the digits successfully retrieved by the user during the interaction.
In theory, the SRP should return no digits at all in the case where insufficient digits are entered. However, that behavior can vary according to SRP manufacturer, and the service logic should always validate the number of digits returned.

Note that it is possible to have digits returned even if the interaction was abandoned. This may happen with some SRP behaviors, and/or some timing conditions.

SCP-HANDLE-ALEG-TEARDOWN-FINAL

The SCP-HANDLE-ALEG-TEARDOWN-FINAL message is sent from the LhoScpApp to the LogicApp as a response to SCP-DO-INAP-BLEG-TERMINATION-ATTEMPT if and when the termination attempt is Abandoned (i.e. the oAbandon or tAbandon EDP fires).

After receiving SCP-HANDLE-ALEG-TEARDOWN-FINAL, the call is no longer “controlled” by the service logic.

No further SCP-... messages should be exchanged after this message is sent.

The attributes of the SCP-HANDLE-ALEG-TEARDOWN-FINAL message are:

Field Type Description
scp Object [Required] The SCP control parameters for the message.
.edp_name String [Required] The name of the Event Detection Point which fired.
One of: oAbandon_leg1, or tAbandon_leg1.

SCP-HANDLE-BLEG-ANSWER-FINAL

The SCP-HANDLE-BLEG-ANSWER-FINAL message is sent from the LhoScpApp to the LogicApp as a response to SCP-DO-INAP-BLEG-TERMINATION-ATTEMPT if and when the termination attempt is Answered (i.e. the oAnswer or tAnswer EDP fires).

After receiving SCP-HANDLE-BLEG-ANSWER-FINAL, the call is no longer “controlled” by the service logic.

No further SCP-... messages should be exchanged after this message is sent.

The attributes of the SCP-HANDLE-BLEG-ANSWER-FINAL message are:

Field Type Description
scp Object [Required] The SCP control parameters for the message.
.edp_name String [Required] The name of the Event Detection Point which fired.
One of: oAnswer_leg2, or tAnswer_leg2.

SCP-HANDLE-BLEG-TEARDOWN-ONGOING

The SCP-HANDLE-BLEG-TEARDOWN-ONGOING message is sent from the LhoScpApp to the LogicApp as a response to SCP-DO-INAP-BLEG-TERMINATION-ATTEMPT if and when the termination attempt fails due to Busy, NoAnswer, or RouteSelectFailure but the A-Leg is still active.

After receiving SCP-HANDLE-BLEG-TEARDOWN-ONGOING, the call is still “controlled” by the service logic. The service logic must (within the service logic timer) send one of the following SCP control messages:

The attributes of the SCP-HANDLE-BLEG-TEARDOWN-ONGOING message are:

Field Type Description
scp Object [Required] The SCP control parameters for the message.
.edp_name String [Required] The name of the Event Detection Point which fired.
One of: oCalledPartyBusy_leg2, tBusy_leg2, oNoAnswer_leg2, tNoAnswer_leg2, or routeSelectFailure_leg2.

SCP-HANDLE-SHUTDOWN

The SCP-HANDLE-SHUTDOWN is sent by the LhoScpApp to the LogicApp to indicate that call processing has failed unexpectedly and cannot continue. The LhoScpApp has perform any necessary TCAP transaction closure, typically using TCAP_ABORT, and has raised a warning.

No further SCP-... messages should be exchanged after this message is sent.

The attributes of the SCP-HANDLE-SHUTDOWN message are:

Field Type Description
success 0 [Required] Indicator that the call processing was not successful.
error String [Required] The descriptive error message raised in the warning.