Endpoint: {
    meta?: Record<string, any>;
    method?: HTTPMethod;
    target: string;
}

The definition of an API endpoint to be listed in the APIConfig.endpoints map

Type declaration

  • Optionalmeta?: Record<string, any>

    Any metadata that should be attached to the endpoint's requests for later reference

  • Optionalmethod?: HTTPMethod

    The HTTP method of the endpoint. Defaults to GET

  • target: string

    The path of the endpoint relative to the API APIConfig.baseURL