Container List With Sort And Filters

Get a paginated list of containers with optional sorting and filtering.

This endpoint retrieves a list of containers, with the ability to sort the results by the specified column and apply various filters on the container attributes.

Arguments:

  • order_by: An optional object that specifies the sorting order. The object should have two attributes:

    • name: The column name to sort the results by. Must be a valid column name in the Container model. (e.g., id, vessel_atd_dt)
    • dir: The direction of the sort. 1 for ascending order and -1 for descending order.
  • filter_value: An optional list of filter objects to apply on the container attributes. Each filter object should have the following attributes:

    • name: The column name to apply the filter on. Must be a valid column name in the Container model. (e.g., id, vessel_atd_dt)
    • operator: The filter operator to use. Must be one of the following values: eq, neq, gt, gte, lt, lte, contains, not_contains, starts_with, ends_with, is_null, is_not_null, in, not_in.
  • value: The value to compare against, if applicable (not required for is_null and is_not_null operators).

Filter Operators:

  • eq: Equal to
  • neq: Not equal to
  • gt: Greater than
  • gte: Greater than or equal to
  • lt: Less than
  • lte: Less than or equal to
  • contains: Contains substring
  • not_contains: Does not contain substring
  • starts_with: Starts with substring
  • ends_with: Ends with substring
  • is_null: Is null
  • is_not_null: Is not null
  • in: Value is in a list of comma-separated values
  • not_in: Value is not in a list of comma-separated values

Example request body for sorting and filtering:

{
  "order_by": {
    "name": "vessel_atd_dt",
    "dir": -1
  },
  "filter_value": [
    {
      "name": "name",
      "operator": "contains",
      "value": "example"
    }
  ]
}

In the example above, the results will be sorted by the vessel_atd_dt column in descending order and filtered to only include containers whose name contains the substring "example".

Language
Credentials
OAuth2
Response
Click Try It! to start a request and see the response here!