Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

GET - /api/v1/services/{id}/regulated-entities

Parameters

Parameter

Description

Type

id

The service id associated to the regulated entity.

Path

type

The entity type of the regulated type (ex. VESSEL). This is case insensitive.

Query string

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 request response

Code Block
languagejson
[
  {
    "Id": 1,
    "EnglishDisplayName": "Vessel Name",
    "FrenchDisplayName": "Nom du bâtiment"
  },
  {
    "Id": 2,
    "EnglishDisplayName": "Canadian Vessel?",
    "FrenchDisplayName": "Bâtiment canadien?"
  },
  {
    "Id": 3,
    "EnglishDisplayName": "IMO",
    "FrenchDisplayName": "OMI"
  },
  {
    "Id": 4,
    "EnglishDisplayName": "Official No.",
    "FrenchDisplayName": "Numéro officiel"
  }
]

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.

...

Example

Code Block
languagec#
//Use your service id and entity type.
const int serviceId = 1230;
const string entity = "VESSEL";

var serviceRegulatedEntityIdTypes = await MtoaApi.ServiceRegulatedEntityApi.GetList(serviceId, entity);