Add
Description
Adds a collection regulated entity ids for a specified service request.
Package Details
Interface
IServiceRegulatedEntityManager
Syntax
Task<ICollection<ServiceRegulatedEntity>> Add(int serviceRequestId, ICollection<ServiceRegulatedEntity> serviceRegulatedEntities)
Returns
ICollection<ServiceRegulatedEntity>
API
POST - /api/v1/regulated-entities
Parameters
Parameter | Description | Type |
---|---|---|
serviceRequestId | The service request id associated to the regulated entity. The service request must exist. | Query string |
Sample request body – This is a sample which adds the values of the regulated entity ids for the specified service request.
Notes: Only the values should be modified. The values are associated to an entity id. You cannot use the same service request id when adding new regulated entities. This is a constraint in the database.
This example is for service id 123 and type VESSEL. You can get a list from the GetList page.
Returns
HTTP 200 - OK
Returns a list of regulated entities with their ids, English and French display names. The ids are returned based on a sort order.
Is there’s no regulated entity ids found, an empty list is returned.
Sample response body – Returns the added values.
Example
Note: Make sure to use the proper ids from the GetList function.