Application Programming Interface (API)

Use

The provider order Application Programming Interface (API) provides another maintenance option in provider order and contracts maintenance in addition to the existing Web-based UIs (Interaction Center, Back Office).

The main use cases are:

  • Order capturing in a pre-system, for example external CRM, mobile client, WebChannel

  • Migration

  • Automated contract changes (for example extensions)

  • Mass run

The API offers “one shot” operations, for example methods that have a complex interface and only allow a single call to perform a task. For example, creating a sales order requires all item details including the correct configuration data, or technical resources.

You have the following options:

  • You can create a provider order and prepare it later in the UI. This is the same functionality as that provided in IC WebClient or the Back Office.

  • You can create a provider order and a contract in a single step. This is the same functionality as that provided in IC WebClient or the Back Office.

  • You can create a provider contract without a referenced order. You can create several contracts in a single step.

  • You can change the contracts.

  • You can lock and unlock contracts

To create or change provider orders and contracts, the following methods and RFC function modules are available:

  • Create a provider order and contract with a referenced order

    • Method: CL_CRM_ISX_PROV_ORDER_API_PRXY=>ORDER_CREATE

    • RFC function Module: CRM_ISX_BTX_API_ORDER_CREATE

  • Create a provider contract without a referenced order

    • Method: CL_CRM_ISX_PROV_ORDER_API_PRXY=>CONTRACT_CREATE

    • RFC function module: CRM_ISX_BTX_API_CONT_CREATE

  • Change a provider contract

    • Method: CL_CRM_ISX_PROV_ORDER_API_PRXY=>CONTRACT_CHANGE

    • RFC function module: CRM_ISX_BTX_API_CONT_CHANGE

      • Process attributes must be passed using the interface component CRMT_ISX_CONTRACT_CHANGE_RFC-PROCESS_ATTRIBUTES



The import structure of the API contains the order data to be created or changed and a set of control indicators that control how the process is executed, for example whether a commit is to be performed.

The export structure of the API returns information about the created or changed objects, for example document numbers and messages that occurred during processing, such as error messages.

Lock or unlock a contract

RFC function module CRM_ISX_BTX_API_LOCK_CREATE

The import structure of the function module contains the following fields:

  • CONTRACT_GUID: Contract item GUID

  • LOCK_GUID: Lock GUID (optional). If it is not filled, the lock GUID is created within the function module

  • LOCK_TIME: Lock time as timestamp (optional). If it is not filled, the current time stamp is taken as the lock time

  • LOCK_REASON: Lock reason for the provider service object

You can also select the checkbox Commit. The following export parameters exist:

  • Execution status of the lock (domain fixed values)

  • Return table of error messages

Prerequisites

You have maintained the following data in the system:

  • Partner master data to be used.

  • Sales organization: This has to be created with all components such as the sales organization, sales office, sales group, distribution channel, and division. The partner can have a specific default sales organization.

  • Process type: A business transaction type is required to create an order or contract.

  • Product: Prices have to be maintained at different intervals for the corresponding sales organization. In Customizing, you can define the way in which the price is to be determined. For example, the contract start can be used as the basis for price determination. You must maintain the access date for the condition type. This can be done in Customizing for Customer Relationship Management under Start of the navigation pathBasic Functions Next navigation step Pricing Next navigation step Create Condition TypeEnd of the navigation path. Select a specific condition type, for example monthly fee, and maintain the field access date for it. To obtain the prices that are relevant to the activation date of contract, select the entry PRVO_ACTIVATION_TIMESTAMP.

  • Customizing settings of technical resource.

  • Contract change: You have set up the Business Transaction Maintenance Framework (BTMF framework) as required. You have defined and implemented the relevant BTMF process. A process that can be used by the API has to ensure that all required input data is provided by the API interface. Therefore, a generic collection of name value pairs is available. This data can be accessed from the process using a global data container (BTMF container).

    In most cases you must maintain these name value pairs. This is shown in table form in the document for each process. You can see which names have to be entered. For example to cancel the provider contract, you have to enter the requested/received cancellation date, cancellation procedure and reason. For more information, see Provider Contract Changes.

    Most of the BTMF processes shipped in the standard SAP standard delivery system use this container to obtain process data.

Limitations

Observe the following limitations when using the provider API:

  • Multi-level configuration is not supported (configurable product must not contain another configurable product defined in the same product model)

  • Attribute item usage is determined from the attribute product role available in the sales data for the product as follows:

    • If the parent item is Sales Package, the usage is Sales Component (‘16’).

    • If the parent item is Rate Plan and the parent is configurable, the usage is Configuration (‘01’); otherwise, the usage is Dependent Component (‘18’).

    • If there is no parent, the usage is space.

  • When using the configuration, the system assumes that only rate plans are used and a rate plan is not used as a dependent component.

  • The partner function SOLD_TO is available at header level only (corresponds to the UI) and cannot be overwritten at item level separately.

Enhancement Spot: CRM_ISX_BTX_API

You can use the enhancement spot CRM_ISX_BTX_API to define the behavior of fields that are not covered by the standard API structure.