Skip to main content

Assigning APIs to a Module

After a collection is chosen on an external module, five API slots appear. Each slot takes one API from the same collection. The module calls the matching API whenever an agent lists, opens, creates, changes or deletes a record. In the example, Policy Customers uses List Customers for its list and Get Customer for a single record.

New external module form with PolicyHub KYC selected and the Get All API, Get API and Post API fields shown as empty dropdowns

Figure 1. The API slots that appear once a collection is chosen on an external module.

The API Slots​

SlotRequiredUsed for
Get All APINeeded for the list viewThe base API. It returns the list of records shown in the module's list view.
Get APIRecommendedA GET API that returns one record, used when a record is opened.
Post APIOptionalA POST API that creates a record.
Update APIOptionalA PUT or PATCH API that changes a record.
Delete APIOptionalA DELETE API that removes a record.

Assigning the APIs​

  1. Open the Get All API dropdown and choose the list API. For example List Customers.
  2. Open the Get API dropdown and choose the single record API. For example Get Customer.
  3. Choose the optional APIs only for the actions agents should have. Leave Post, Update and Delete empty for a module that is only for looking up records.
  4. Click Save.

External module form with the collection PolicyHub KYC, List Customers as the Get All API, Get Customer as the Get API, and the Post, Update and Delete API fields left empty

Figure 2. The API slots filled in for Policy Customers. Post API, Update API and Delete API are left empty, so the module is a lookup only.

warning

The Get All API must return the response format the CRM requires, and its response schema must be saved by running the API with Send. Otherwise the form shows an error under the field. See Response Format the CRM Requires.

tip

Leave the Post, Update and Delete slots empty when the module should be a lookup only. Agents then cannot change records in the outside system from the CRM.