Documentation ¶
Index ¶
- Variables
- func CacheExpires(r *http.Response) time.Time
- type APIClient
- type APIKey
- type APIResponse
- type Account
- type AccountAttributes
- type BasicAuth
- type Configuration
- type Container
- type ContainerAttributes
- type ContainerUpdatedEvent
- type ContainerUpdatedEventAttributes
- type ContainerUpdatedEventRelationships
- type ContainerUpdatedEventRelationshipsContainer
- type ContainerUpdatedEventRelationshipsContainerData
- type ContainerUpdatedEventRelationshipsTerminal
- type ContainerUpdatedEventRelationshipsTerminalData
- type ContainersApiService
- func (a *ContainersApiService) GetContainers(ctx _context.Context, localVarOptionals *GetContainersOpts) (InlineResponse2008, *_nethttp.Response, error)
- func (a *ContainersApiService) GetContainersId(ctx _context.Context, id string, localVarOptionals *GetContainersIdOpts) (InlineResponse2009, *_nethttp.Response, error)
- func (a *ContainersApiService) GetContainersIdRawEvents(ctx _context.Context, id string) (InlineResponse20010, *_nethttp.Response, error)
- func (a *ContainersApiService) GetContainersIdTransportEvents(ctx _context.Context, id string, ...) (InlineResponse20011, *_nethttp.Response, error)
- type ErrorSource
- type EstimatedEvent
- type EstimatedEventAttributes
- type EstimatedEventRelationships
- type EstimatedEventRelationshipsShipment
- type EstimatedEventRelationshipsShipmentData
- type EstimatedEventRelationshipsVessel
- type EstimatedEventRelationshipsVesselData
- type GenericOpenAPIError
- type GetContainersIdOpts
- type GetContainersIdTransportEventsOpts
- type GetContainersOpts
- type GetShipmentIdOpts
- type GetShipmentsOpts
- type GetShippingLinesOpts
- type GetTrackRequestByIdOpts
- type GetTrackingRequestsOpts
- type GetWebhookNotificationIdOpts
- type GetWebhookNotificationsOpts
- type GetWebhooksOpts
- type InlineObject
- type InlineObject1
- type InlineObject2
- type InlineResponse200
- type InlineResponse2001
- type InlineResponse20010
- type InlineResponse20011
- type InlineResponse20012
- type InlineResponse20013
- type InlineResponse2002
- type InlineResponse2003
- type InlineResponse2004
- type InlineResponse2005
- type InlineResponse2006
- type InlineResponse2007
- type InlineResponse2008
- type InlineResponse2009
- type InlineResponse201
- type InlineResponse422
- type Links
- type Meta
- type MetroArea
- type MetroAreaAttributes
- type ModelError
- type PatchWebhooksIdOpts
- type Port
- type PortAttributes
- type PostTrackOpts
- type PostWebhooksOpts
- type RailTerminal
- type RailTerminalRelationships
- type RailTerminalRelationshipsMetroArea
- type RailTerminalRelationshipsMetroAreaData
- type RawEvent
- type RawEventAttributes
- type RawEventRelationships
- type ServerConfiguration
- type ServerVariable
- type Shipment
- type ShipmentAttributes
- type ShipmentRelationships
- type ShipmentRelationshipsContainers
- type ShipmentRelationshipsContainersData
- type ShipmentRelationshipsCustomer
- type ShipmentRelationshipsCustomerData
- type ShipmentRelationshipsDestination
- type ShipmentRelationshipsDestinationData
- type ShipmentRelationshipsDestinationTerminal
- type ShipmentRelationshipsPodTerminal
- type ShipmentRelationshipsPortOfLading
- type ShipmentRelationshipsPortOfLadingData
- type ShipmentsApiService
- func (a *ShipmentsApiService) GetShipmentId(ctx _context.Context, id string, localVarOptionals *GetShipmentIdOpts) (InlineResponse2001, *_nethttp.Response, error)
- func (a *ShipmentsApiService) GetShipments(ctx _context.Context, localVarOptionals *GetShipmentsOpts) (InlineResponse200, *_nethttp.Response, error)
- type ShippingLine
- type ShippingLineAttributes
- type ShippingLinesApiService
- type Terminal
- type TerminalAttributes
- type TerminalFee
- type TerminalHold
- type TerminalRelationships
- type TerminalRelationshipsPort
- type TerminalRelationshipsPortData
- type TrackingRequest
- type TrackingRequestAttributes
- type TrackingRequestRelationships
- type TrackingRequestRelationshipsTrackedObject
- type TrackingRequestRelationshipsTrackedObjectData
- type TrackingRequestsApiService
- func (a *TrackingRequestsApiService) GetTrackRequestById(ctx _context.Context, id string, localVarOptionals *GetTrackRequestByIdOpts) (InlineResponse2003, *_nethttp.Response, error)
- func (a *TrackingRequestsApiService) GetTrackingRequests(ctx _context.Context, localVarOptionals *GetTrackingRequestsOpts) (InlineResponse2002, *_nethttp.Response, error)
- func (a *TrackingRequestsApiService) PostTrack(ctx _context.Context, localVarOptionals *PostTrackOpts) (InlineResponse201, *_nethttp.Response, error)
- type TrackingRequestsData
- type TrackingRequestsDataAttributes
- type TransportEvent
- type TransportEventAttributes
- type TransportEventRelationships
- type TransportEventRelationshipsContainer
- type TransportEventRelationshipsContainerData
- type TransportEventRelationshipsLocation
- type TransportEventRelationshipsLocationData
- type TransportEventRelationshipsTerminal
- type TransportEventRelationshipsTerminalData
- type TransportEventRelationshipsVessel
- type TransportEventRelationshipsVesselData
- type Vessel
- type VesselAttributes
- type Webhook
- type WebhookAttributes
- type WebhookAttributesHeaders
- type WebhookNotification
- type WebhookNotificationAttributes
- type WebhookNotificationRelationships
- type WebhookNotificationRelationshipsReferenceObject
- type WebhookNotificationRelationshipsReferenceObjectData
- type WebhookNotificationRelationshipsWebhook
- type WebhookNotificationRelationshipsWebhookData
- type WebhookNotificationsApiService
- func (a *WebhookNotificationsApiService) GetWebhookNotificationId(ctx _context.Context, id string, ...) (InlineResponse2006, *_nethttp.Response, error)
- func (a *WebhookNotificationsApiService) GetWebhookNotifications(ctx _context.Context, localVarOptionals *GetWebhookNotificationsOpts) (InlineResponse2007, *_nethttp.Response, error)
- type WebhooksApiService
- func (a *WebhooksApiService) DeleteWebhooksId(ctx _context.Context, id string) (*_nethttp.Response, error)
- func (a *WebhooksApiService) GetWebhooks(ctx _context.Context, localVarOptionals *GetWebhooksOpts) (InlineResponse2005, *_nethttp.Response, error)
- func (a *WebhooksApiService) GetWebhooksId(ctx _context.Context, id string) (InlineResponse2004, *_nethttp.Response, error)
- func (a *WebhooksApiService) PatchWebhooksId(ctx _context.Context, id string, localVarOptionals *PatchWebhooksIdOpts) (InlineResponse2004, *_nethttp.Response, error)
- func (a *WebhooksApiService) PostWebhooks(ctx _context.Context, localVarOptionals *PostWebhooksOpts) (InlineResponse2004, *_nethttp.Response, error)
- type WebhooksData
- type WebhooksDataAttributes
- type WebhooksDataAttributesHeaders
- type WebhooksIdData
- type WebhooksIdDataAttributes
- type WebhooksIdDataAttributesHeaders
Constants ¶
This section is empty.
Variables ¶
var ( // ContextOAuth2 takes an oauth2.TokenSource as authentication for the request. ContextOAuth2 = contextKey("token") // ContextBasicAuth takes BasicAuth as authentication for the request. ContextBasicAuth = contextKey("basic") // ContextAccessToken takes a string oauth2 access token as authentication for the request. ContextAccessToken = contextKey("accesstoken") // ContextAPIKey takes an APIKey as authentication for the request ContextAPIKey = contextKey("apikey") )
Functions ¶
Types ¶
type APIClient ¶
type APIClient struct { ContainersApi *ContainersApiService ShipmentsApi *ShipmentsApiService ShippingLinesApi *ShippingLinesApiService TrackingRequestsApi *TrackingRequestsApiService WebhookNotificationsApi *WebhookNotificationsApiService WebhooksApi *WebhooksApiService // contains filtered or unexported fields }
APIClient manages communication with the Terminal49 API Reference API v0.2.0 In most cases there should be only one, shared, APIClient.
func NewAPIClient ¶
func NewAPIClient(cfg *Configuration) *APIClient
NewAPIClient creates a new API client. Requires a userAgent string describing your application. optionally a custom http.Client to allow for advanced features such as caching.
func (*APIClient) ChangeBasePath ¶
ChangeBasePath changes base path to allow switching to mocks
func (*APIClient) GetConfig ¶
func (c *APIClient) GetConfig() *Configuration
Allow modification of underlying config for alternate implementations and testing Caution: modifying the configuration while live can cause data races and potentially unwanted behavior
type APIKey ¶
APIKey provides API key based authentication to a request passed via context using ContextAPIKey
type APIResponse ¶
type APIResponse struct { *http.Response `json:"-"` Message string `json:"message,omitempty"` // Operation is the name of the OpenAPI operation. Operation string `json:"operation,omitempty"` // RequestURL is the request URL. This value is always available, even if the // embedded *http.Response is nil. RequestURL string `json:"url,omitempty"` // Method is the HTTP method used for the request. This value is always // available, even if the embedded *http.Response is nil. Method string `json:"method,omitempty"` // Payload holds the contents of the response body (which may be nil or empty). // This is provided here as the raw response.Body() reader will have already // been drained. Payload []byte `json:"-"` }
APIResponse stores the API response returned by the server.
func NewAPIResponse ¶
func NewAPIResponse(r *http.Response) *APIResponse
NewAPIResponse returns a new APIResonse object.
func NewAPIResponseWithError ¶
func NewAPIResponseWithError(errorMessage string) *APIResponse
NewAPIResponseWithError returns a new APIResponse object with the provided error message.
type Account ¶
type Account struct { Id string `json:"id"` Type string `json:"type"` Attributes AccountAttributes `json:"attributes"` }
Account struct for Account
type AccountAttributes ¶
type AccountAttributes struct {
CompanyName string `json:"company_name"`
}
AccountAttributes struct for AccountAttributes
type BasicAuth ¶
type BasicAuth struct { UserName string `json:"userName,omitempty"` Password string `json:"password,omitempty"` }
BasicAuth provides basic http authentication to a request passed via context using ContextBasicAuth
type Configuration ¶
type Configuration struct { BasePath string `json:"basePath,omitempty"` Host string `json:"host,omitempty"` Scheme string `json:"scheme,omitempty"` DefaultHeader map[string]string `json:"defaultHeader,omitempty"` UserAgent string `json:"userAgent,omitempty"` Debug bool `json:"debug,omitempty"` Servers []ServerConfiguration HTTPClient *http.Client }
Configuration stores the configuration of the API client
func NewConfiguration ¶
func NewConfiguration() *Configuration
NewConfiguration returns a new Configuration object
func (*Configuration) AddDefaultHeader ¶
func (c *Configuration) AddDefaultHeader(key string, value string)
AddDefaultHeader adds a new HTTP header to the default header in the request
type Container ¶
type Container struct { Id string `json:"id"` Attributes ContainerAttributes `json:"attributes,omitempty"` }
Container Represents the equipment during a specific journey.
type ContainerAttributes ¶
type ContainerAttributes struct { Number string `json:"number,omitempty"` EquipmentType *string `json:"equipment_type,omitempty"` EquipmentLength *int32 `json:"equipment_length,omitempty"` EquipmentHeight *string `json:"equipment_height,omitempty"` WeightInLbs *float32 `json:"weight_in_lbs,omitempty"` CreatedAt time.Time `json:"created_at,omitempty"` SealNumber *string `json:"seal_number,omitempty"` // The last free day for pickup before deummurage accrues. PickupLfd *time.Time `json:"pickup_lfd,omitempty"` // When available the pickup appointment time at the terminal is returned. PickupAppointmentAt *time.Time `json:"pickup_appointment_at,omitempty"` // Whether Terminal 49 is receiving availability status from the terminal. AvailabilityKnown bool `json:"availability_known,omitempty"` // If availability_known is true, then whether container is available to be picked up at terminal. AvailableForPickup *bool `json:"available_for_pickup,omitempty"` // Time the vessel arrived at the POD PodArrivedAt *time.Time `json:"pod_arrived_at,omitempty"` // Discharge time at the port of discharge PodDischargedAt *time.Time `json:"pod_discharged_at,omitempty"` // Full Out time at port of discharge. Null for inland moves. PodFullOutAt *time.Time `json:"pod_full_out_at,omitempty"` // The chassis number used when container was picked up at POD (if available) PodFullOutChassisNumber *string `json:"pod_full_out_chassis_number,omitempty"` // Pickup time at final destination for inland moves. FinalDestinationFullOutAt *time.Time `json:"final_destination_full_out_at,omitempty"` // Time empty container was returned. EmptyTerminatedAt *time.Time `json:"empty_terminated_at,omitempty"` HoldsAtPodTerminal []TerminalHold `json:"holds_at_pod_terminal,omitempty"` FeesAtPodTerminal []TerminalFee `json:"fees_at_pod_terminal,omitempty"` }
ContainerAttributes struct for ContainerAttributes
type ContainerUpdatedEvent ¶
type ContainerUpdatedEvent struct { Id string `json:"id,omitempty"` Type string `json:"type,omitempty"` Attributes ContainerUpdatedEventAttributes `json:"attributes,omitempty"` Relationships ContainerUpdatedEventRelationships `json:"relationships"` }
ContainerUpdatedEvent struct for ContainerUpdatedEvent
type ContainerUpdatedEventAttributes ¶
type ContainerUpdatedEventAttributes struct { // A hash of all the changed attributes with the values being an array of the before and after. E.g. `{\"pickup_lfd\": [null, \"2020-05-20\"]}` The current attributes that can be alerted on are: - `available_for_pickup` - `pickup_lfd` - `fees_at_pod_terminal` - `holds_at_pod_terminal` Changeset map[string]interface{} `json:"changeset"` Timestamp time.Time `json:"timestamp"` // IANA tz Timezone string `json:"timezone,omitempty"` }
ContainerUpdatedEventAttributes struct for ContainerUpdatedEventAttributes
type ContainerUpdatedEventRelationships ¶
type ContainerUpdatedEventRelationships struct { Container ContainerUpdatedEventRelationshipsContainer `json:"container"` Terminal ContainerUpdatedEventRelationshipsTerminal `json:"terminal"` }
ContainerUpdatedEventRelationships struct for ContainerUpdatedEventRelationships
type ContainerUpdatedEventRelationshipsContainer ¶
type ContainerUpdatedEventRelationshipsContainer struct {
Data ContainerUpdatedEventRelationshipsContainerData `json:"data"`
}
ContainerUpdatedEventRelationshipsContainer struct for ContainerUpdatedEventRelationshipsContainer
type ContainerUpdatedEventRelationshipsContainerData ¶
type ContainerUpdatedEventRelationshipsContainerData struct { Id string `json:"id"` Type string `json:"type"` }
ContainerUpdatedEventRelationshipsContainerData struct for ContainerUpdatedEventRelationshipsContainerData
type ContainerUpdatedEventRelationshipsTerminal ¶
type ContainerUpdatedEventRelationshipsTerminal struct {
Data ContainerUpdatedEventRelationshipsTerminalData `json:"data"`
}
ContainerUpdatedEventRelationshipsTerminal struct for ContainerUpdatedEventRelationshipsTerminal
type ContainerUpdatedEventRelationshipsTerminalData ¶
type ContainerUpdatedEventRelationshipsTerminalData struct { Id string `json:"id"` Type string `json:"type"` }
ContainerUpdatedEventRelationshipsTerminalData struct for ContainerUpdatedEventRelationshipsTerminalData
type ContainersApiService ¶
type ContainersApiService service
ContainersApiService ContainersApi service
func (*ContainersApiService) GetContainers ¶
func (a *ContainersApiService) GetContainers(ctx _context.Context, localVarOptionals *GetContainersOpts) (InlineResponse2008, *_nethttp.Response, error)
GetContainers List containers Returns a list of container. The containers are returned sorted by creation date, with the most recent container appearing first. This API will return all containers associated with the account.
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param optional nil or *GetContainersOpts - Optional Parameters:
- @param "PageNumber" (optional.Int32) -
- @param "PageSize" (optional.Int32) -
- @param "Include" (optional.String) - Comma delimited list of relations to include
@return InlineResponse2008
func (*ContainersApiService) GetContainersId ¶
func (a *ContainersApiService) GetContainersId(ctx _context.Context, id string, localVarOptionals *GetContainersIdOpts) (InlineResponse2009, *_nethttp.Response, error)
GetContainersId Get a container Retrieves the details of a container.
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param id
- @param optional nil or *GetContainersIdOpts - Optional Parameters:
- @param "Include" (optional.String) - Comma delimited list of relations to include
@return InlineResponse2009
func (*ContainersApiService) GetContainersIdRawEvents ¶
func (a *ContainersApiService) GetContainersIdRawEvents(ctx _context.Context, id string) (InlineResponse20010, *_nethttp.Response, error)
GetContainersIdRawEvents Get a container's raw events Get a list of past and futuer (estimated) milestones for a container as reported by the carrier. Some of the data is normalized even though the API is called raw_events. Normalized attributes: `event`, `estimated_at`, `actual_at` timestamps. Not all of the `event` values have been normalized. You can expect the the events related to container movements to be normalized but there are cases (paperwork \"milestones\" like customs release) where events are not normalized.
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param id
@return InlineResponse20010
func (*ContainersApiService) GetContainersIdTransportEvents ¶
func (a *ContainersApiService) GetContainersIdTransportEvents(ctx _context.Context, id string, localVarOptionals *GetContainersIdTransportEventsOpts) (InlineResponse20011, *_nethttp.Response, error)
GetContainersIdTransportEvents Get a container's transport events Get a list of past transport events (canonical) for a container. All data has been normalized across all carriers. These are a verified subset of the raw events may also be sent as Webhook Notifications to a webhook endpoint. This does not provide any estiamted future events. See `container/:id/raw_events` endpoint for that.
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param id
- @param optional nil or *GetContainersIdTransportEventsOpts - Optional Parameters:
- @param "Include" (optional.String) - Comma delimited list of relations to include
@return InlineResponse20011
type ErrorSource ¶
type ErrorSource struct {
Pointer string `json:"pointer,omitempty"`
}
ErrorSource struct for ErrorSource
type EstimatedEvent ¶
type EstimatedEvent struct { Id string `json:"id"` Type string `json:"type"` Attributes EstimatedEventAttributes `json:"attributes"` Relationships EstimatedEventRelationships `json:"relationships"` }
EstimatedEvent struct for EstimatedEvent
type EstimatedEventAttributes ¶
type EstimatedEventAttributes struct { // When the estimated event was created CreatedAt time.Time `json:"created_at"` EstimatedTimestamp time.Time `json:"estimated_timestamp"` Event string `json:"event"` // UNLOCODE of the event location LocationLocode *string `json:"location_locode,omitempty"` // IANA tz Timezone *string `json:"timezone,omitempty"` VoyageNumber *string `json:"voyage_number,omitempty"` }
EstimatedEventAttributes struct for EstimatedEventAttributes
type EstimatedEventRelationships ¶
type EstimatedEventRelationships struct { Shipment EstimatedEventRelationshipsShipment `json:"shipment"` Port TerminalRelationshipsPort `json:"port,omitempty"` Vessel EstimatedEventRelationshipsVessel `json:"vessel,omitempty"` }
EstimatedEventRelationships struct for EstimatedEventRelationships
type EstimatedEventRelationshipsShipment ¶
type EstimatedEventRelationshipsShipment struct {
Data EstimatedEventRelationshipsShipmentData `json:"data"`
}
EstimatedEventRelationshipsShipment struct for EstimatedEventRelationshipsShipment
type EstimatedEventRelationshipsShipmentData ¶
type EstimatedEventRelationshipsShipmentData struct { Id string `json:"id"` Type string `json:"type"` }
EstimatedEventRelationshipsShipmentData struct for EstimatedEventRelationshipsShipmentData
type EstimatedEventRelationshipsVessel ¶
type EstimatedEventRelationshipsVessel struct {
Data EstimatedEventRelationshipsVesselData `json:"data,omitempty"`
}
EstimatedEventRelationshipsVessel struct for EstimatedEventRelationshipsVessel
type EstimatedEventRelationshipsVesselData ¶ added in v1.0.3
type EstimatedEventRelationshipsVesselData struct { Id string `json:"id,omitempty"` Type string `json:"type,omitempty"` }
EstimatedEventRelationshipsVesselData struct for EstimatedEventRelationshipsVesselData
type GenericOpenAPIError ¶
type GenericOpenAPIError struct {
// contains filtered or unexported fields
}
GenericOpenAPIError Provides access to the body, error and model on returned errors.
func (GenericOpenAPIError) Body ¶
func (e GenericOpenAPIError) Body() []byte
Body returns the raw bytes of the response
func (GenericOpenAPIError) Error ¶
func (e GenericOpenAPIError) Error() string
Error returns non-empty string if there was an error.
func (GenericOpenAPIError) Model ¶
func (e GenericOpenAPIError) Model() interface{}
Model returns the unpacked model of the error
type GetContainersIdOpts ¶ added in v1.0.3
GetContainersIdOpts Optional parameters for the method 'GetContainersId'
type GetContainersIdTransportEventsOpts ¶ added in v1.0.3
GetContainersIdTransportEventsOpts Optional parameters for the method 'GetContainersIdTransportEvents'
type GetContainersOpts ¶
type GetContainersOpts struct { PageNumber optional.Int32 PageSize optional.Int32 Include optional.String }
GetContainersOpts Optional parameters for the method 'GetContainers'
type GetShipmentIdOpts ¶ added in v1.0.3
GetShipmentIdOpts Optional parameters for the method 'GetShipmentId'
type GetShipmentsOpts ¶
type GetShipmentsOpts struct { PageNumber optional.Int32 PageSize optional.Int32 Q optional.String Include optional.String Number optional.String }
GetShipmentsOpts Optional parameters for the method 'GetShipments'
type GetShippingLinesOpts ¶ added in v1.1.0
type GetShippingLinesOpts struct {
Body map[string]interface{}
}
GetShippingLinesOpts Optional parameters for the method 'GetShippingLines'
type GetTrackRequestByIdOpts ¶ added in v1.0.3
GetTrackRequestByIdOpts Optional parameters for the method 'GetTrackRequestById'
type GetTrackingRequestsOpts ¶
type GetTrackingRequestsOpts struct { Q optional.String FilterStatus optional.String FilterScac optional.String FilterCreatedAtStart optional.Time FilterCreatedAtEnd optional.Time Include optional.String PageNumber optional.Int32 PageSize optional.Int32 RequestNumber optional.String }
GetTrackingRequestsOpts Optional parameters for the method 'GetTrackingRequests'
type GetWebhookNotificationIdOpts ¶ added in v1.0.3
GetWebhookNotificationIdOpts Optional parameters for the method 'GetWebhookNotificationId'
type GetWebhookNotificationsOpts ¶ added in v1.0.3
type GetWebhookNotificationsOpts struct { PageNumber optional.Int32 PageSize optional.Int32 Include optional.String }
GetWebhookNotificationsOpts Optional parameters for the method 'GetWebhookNotifications'
type GetWebhooksOpts ¶ added in v1.0.3
GetWebhooksOpts Optional parameters for the method 'GetWebhooks'
type InlineObject ¶
type InlineObject struct {
Data TrackingRequestsData `json:"data,omitempty"`
}
InlineObject struct for InlineObject
type InlineObject1 ¶
type InlineObject1 struct {
Data WebhooksIdData `json:"data"`
}
InlineObject1 struct for InlineObject1
type InlineObject2 ¶
type InlineObject2 struct {
Data WebhooksData `json:"data"`
}
InlineObject2 struct for InlineObject2
type InlineResponse200 ¶
type InlineResponse200 struct { Data []Shipment `json:"data,omitempty"` Included []interface{} `json:"included,omitempty"` Links Links `json:"links,omitempty"` Meta Meta `json:"meta,omitempty"` }
InlineResponse200 struct for InlineResponse200
type InlineResponse2001 ¶
type InlineResponse2001 struct { Data Shipment `json:"data,omitempty"` Included []interface{} `json:"included,omitempty"` }
InlineResponse2001 struct for InlineResponse2001
type InlineResponse20010 ¶
type InlineResponse20010 struct {
Data []RawEvent `json:"data,omitempty"`
}
InlineResponse20010 struct for InlineResponse20010
type InlineResponse20011 ¶
type InlineResponse20011 struct { Data []TransportEvent `json:"data,omitempty"` Included []interface{} `json:"included,omitempty"` Links Links `json:"links,omitempty"` Meta Meta `json:"meta,omitempty"` }
InlineResponse20011 struct for InlineResponse20011
type InlineResponse20012 ¶ added in v1.1.0
type InlineResponse20012 struct { Data []ShippingLine `json:"data,omitempty"` Links Links `json:"links,omitempty"` }
InlineResponse20012 struct for InlineResponse20012
type InlineResponse20013 ¶ added in v1.1.0
type InlineResponse20013 struct {
Data ShippingLine `json:"data,omitempty"`
}
InlineResponse20013 struct for InlineResponse20013
type InlineResponse2002 ¶
type InlineResponse2002 struct { Data []TrackingRequest `json:"data,omitempty"` Links Links `json:"links,omitempty"` Meta Meta `json:"meta,omitempty"` Included []interface{} `json:"included,omitempty"` }
InlineResponse2002 struct for InlineResponse2002
type InlineResponse2003 ¶
type InlineResponse2003 struct { Data TrackingRequest `json:"data,omitempty"` Included []interface{} `json:"included,omitempty"` }
InlineResponse2003 struct for InlineResponse2003
type InlineResponse2004 ¶
type InlineResponse2004 struct {
Data Webhook `json:"data,omitempty"`
}
InlineResponse2004 struct for InlineResponse2004
type InlineResponse2005 ¶
type InlineResponse2005 struct { Data []Webhook `json:"data,omitempty"` Meta Meta `json:"meta,omitempty"` Links Links `json:"links,omitempty"` }
InlineResponse2005 struct for InlineResponse2005
type InlineResponse2006 ¶
type InlineResponse2006 struct { Data WebhookNotification `json:"data,omitempty"` Included []interface{} `json:"included,omitempty"` }
InlineResponse2006 struct for InlineResponse2006
type InlineResponse2007 ¶
type InlineResponse2007 struct { Data []WebhookNotification `json:"data,omitempty"` Links Links `json:"links,omitempty"` Meta Meta `json:"meta,omitempty"` Included []interface{} `json:"included,omitempty"` }
InlineResponse2007 struct for InlineResponse2007
type InlineResponse2008 ¶
type InlineResponse2008 struct { Data []Container `json:"data,omitempty"` Included []Shipment `json:"included,omitempty"` Links Links `json:"links,omitempty"` Meta Meta `json:"meta,omitempty"` }
InlineResponse2008 struct for InlineResponse2008
type InlineResponse2009 ¶
type InlineResponse2009 struct { Data Container `json:"data,omitempty"` Included []interface{} `json:"included,omitempty"` }
InlineResponse2009 struct for InlineResponse2009
type InlineResponse201 ¶
type InlineResponse201 struct { Data TrackingRequest `json:"data,omitempty"` Included []interface{} `json:"included,omitempty"` }
InlineResponse201 struct for InlineResponse201
type InlineResponse422 ¶
type InlineResponse422 struct {
Errors []ModelError `json:"errors,omitempty"`
}
InlineResponse422 struct for InlineResponse422
type Links ¶
type Links struct { Last string `json:"last,omitempty"` Next string `json:"next,omitempty"` Prev string `json:"prev,omitempty"` First string `json:"first,omitempty"` Self string `json:"self,omitempty"` }
Links struct for Links
type MetroArea ¶
type MetroArea struct { Id string `json:"id"` Attributes MetroAreaAttributes `json:"attributes,omitempty"` Type string `json:"type"` }
MetroArea struct for MetroArea
type MetroAreaAttributes ¶
type MetroAreaAttributes struct { Name string `json:"name,omitempty"` // 2 digit country code CountryCode string `json:"country_code,omitempty"` // IANA tz Timezone string `json:"timezone,omitempty"` // UN/LOCODE Code string `json:"code,omitempty"` }
MetroAreaAttributes struct for MetroAreaAttributes
type ModelError ¶
type ModelError struct { Detail string `json:"detail,omitempty"` Title string `json:"title"` Source ErrorSource `json:"source,omitempty"` Code string `json:"code,omitempty"` Status string `json:"status,omitempty"` }
ModelError struct for ModelError
type PatchWebhooksIdOpts ¶
PatchWebhooksIdOpts Optional parameters for the method 'PatchWebhooksId'
type Port ¶
type Port struct { Id string `json:"id"` Attributes PortAttributes `json:"attributes,omitempty"` Type string `json:"type"` }
Port struct for Port
type PortAttributes ¶
type PortAttributes struct { Name string `json:"name,omitempty"` // 2 digit country code CountryCode string `json:"country_code,omitempty"` // IANA tz TimeZone string `json:"time_zone,omitempty"` // UN/LOCODE Code string `json:"code,omitempty"` }
PortAttributes struct for PortAttributes
type PostTrackOpts ¶
PostTrackOpts Optional parameters for the method 'PostTrack'
type PostWebhooksOpts ¶
PostWebhooksOpts Optional parameters for the method 'PostWebhooks'
type RailTerminal ¶
type RailTerminal struct { Id string `json:"id,omitempty"` Relationships RailTerminalRelationships `json:"relationships,omitempty"` Attributes TerminalAttributes `json:"attributes"` Type string `json:"type,omitempty"` }
RailTerminal struct for RailTerminal
type RailTerminalRelationships ¶
type RailTerminalRelationships struct { Port TerminalRelationshipsPort `json:"port,omitempty"` MetroArea RailTerminalRelationshipsMetroArea `json:"metro_area,omitempty"` }
RailTerminalRelationships struct for RailTerminalRelationships
type RailTerminalRelationshipsMetroArea ¶
type RailTerminalRelationshipsMetroArea struct {
Data RailTerminalRelationshipsMetroAreaData `json:"data,omitempty"`
}
RailTerminalRelationshipsMetroArea struct for RailTerminalRelationshipsMetroArea
type RailTerminalRelationshipsMetroAreaData ¶
type RailTerminalRelationshipsMetroAreaData struct { Id string `json:"id,omitempty"` Type string `json:"type,omitempty"` }
RailTerminalRelationshipsMetroAreaData struct for RailTerminalRelationshipsMetroAreaData
type RawEvent ¶
type RawEvent struct { Id string `json:"id,omitempty"` Type string `json:"type,omitempty"` Attributes RawEventAttributes `json:"attributes,omitempty"` Relationships RawEventRelationships `json:"relationships,omitempty"` }
RawEvent Raw Events represent the milestones from the shipping line for a given container. ### About raw_event datetimes The events may include estimated future events. The event is a future event if an `estimated_` timestamp is not null. The datetime properties `actual_on`, `estimated_on`, `actual_at`, and `estimated_at` are all mutually exclusive. When the `time_zone` property is present the datetimes are UTC timestamps, which can be converted to the local time by parsing the provided `time_zone`. When the `time_zone` property is absent, the datetimes represent local times which serialized as UTC timestamps for consistency.
type RawEventAttributes ¶
type RawEventAttributes struct { // Normalized string representing the event Event string `json:"event,omitempty"` // The event name as returned by the carrier OriginalEvent string `json:"original_event,omitempty"` // The date of the event at the event location when no time information is available. ActualOn string `json:"actual_on,omitempty"` // The estimated date of the event at the event location when no time information is available. EstimatedOn string `json:"estimated_on,omitempty"` // The datetime the event transpired in UTC ActualAt time.Time `json:"actual_at,omitempty"` // The estimated datetime the event will occur in UTC EstimatedAt time.Time `json:"estimated_at,omitempty"` // IANA tz where the event occured Timezone string `json:"timezone,omitempty"` // When the raw_event was created in UTC CreatedAt time.Time `json:"created_at,omitempty"` // The city or facility name of the event location LocationName string `json:"location_name,omitempty"` // UNLOCODE of the event location LocationLocode string `json:"location_locode,omitempty"` // The name of the vessel where applicable VesselName string `json:"vessel_name,omitempty"` // The IMO of the vessel where applicable VesselImo string `json:"vessel_imo,omitempty"` // The order of the event. Thishelpful when only dates (i.e. actual_on) are available. Index int32 `json:"index,omitempty"` VoyageNumber string `json:"voyage_number,omitempty"` }
RawEventAttributes struct for RawEventAttributes
type RawEventRelationships ¶
type RawEventRelationships struct { Location TransportEventRelationshipsLocation `json:"location,omitempty"` Vessel EstimatedEventRelationshipsVessel `json:"vessel,omitempty"` }
RawEventRelationships struct for RawEventRelationships
type ServerConfiguration ¶
type ServerConfiguration struct { Url string Description string Variables map[string]ServerVariable }
ServerConfiguration stores the information about a server
type ServerVariable ¶
ServerVariable stores the information about a server variable
type Shipment ¶
type Shipment struct { Id string `json:"id"` Relationships ShipmentRelationships `json:"relationships,omitempty"` Attributes ShipmentAttributes `json:"attributes,omitempty"` Type string `json:"type"` }
Shipment struct for Shipment
type ShipmentAttributes ¶
type ShipmentAttributes struct { BillOfLadingNumber string `json:"bill_of_lading_number"` RefNumbers []string `json:"ref_numbers,omitempty"` CreatedAt time.Time `json:"created_at,omitempty"` // `unreleased` Tags []string `json:"tags,omitempty"` // UN/LOCODE PortOfLadingLocode string `json:"port_of_lading_locode,omitempty"` PortOfLadingName string `json:"port_of_lading_name,omitempty"` // UN/LOCODE PortOfDischargeLocode string `json:"port_of_discharge_locode,omitempty"` PortOfDischargeName string `json:"port_of_discharge_name,omitempty"` // UN/LOCODE DestinationLocode string `json:"destination_locode,omitempty"` DestinationName string `json:"destination_name,omitempty"` ShippingLineScac string `json:"shipping_line_scac,omitempty"` ShippingLineName string `json:"shipping_line_name,omitempty"` PodVesselName string `json:"pod_vessel_name,omitempty"` PodVesselImo string `json:"pod_vessel_imo,omitempty"` PodVoyageNumber string `json:"pod_voyage_number,omitempty"` PolEtdAt *time.Time `json:"pol_etd_at,omitempty"` PolAtdAt *time.Time `json:"pol_atd_at,omitempty"` PodEtaAt *time.Time `json:"pod_eta_at,omitempty"` PodAtaAt *time.Time `json:"pod_ata_at,omitempty"` DestinationEtaAt *time.Time `json:"destination_eta_at,omitempty"` DestinationAtaAt *time.Time `json:"destination_ata_at,omitempty"` // IANA tz PolTimezone *string `json:"pol_timezone,omitempty"` // IANA tz PodTimezone *string `json:"pod_timezone,omitempty"` // IANA tz DestinationTimezone *string `json:"destination_timezone,omitempty"` // When Terminal49 last tried to update the shipment status from the shipping line LineTrackingLastAttemptedAt *time.Time `json:"line_tracking_last_attempted_at,omitempty"` // When Terminal49 last successfully updated the shipment status from the shipping line LineTrackingLastSucceededAt *time.Time `json:"line_tracking_last_succeeded_at,omitempty"` // When Terminal49 stopped checking at the shipping line LineTrackingStoppedAt *time.Time `json:"line_tracking_stopped_at,omitempty"` // The reason Terminal49 stopped checking LineTrackingStoppedReason *string `json:"line_tracking_stopped_reason,omitempty"` }
ShipmentAttributes struct for ShipmentAttributes
type ShipmentRelationships ¶
type ShipmentRelationships struct { Destination ShipmentRelationshipsDestination `json:"destination,omitempty"` PortOfLading ShipmentRelationshipsPortOfLading `json:"port_of_lading,omitempty"` Containers ShipmentRelationshipsContainers `json:"containers,omitempty"` PortOfDischarge ShipmentRelationshipsPortOfLading `json:"port_of_discharge,omitempty"` Customer ShipmentRelationshipsCustomer `json:"customer,omitempty"` PodTerminal ShipmentRelationshipsPodTerminal `json:"pod_terminal,omitempty"` DestinationTerminal ShipmentRelationshipsDestinationTerminal `json:"destination_terminal,omitempty"` }
ShipmentRelationships struct for ShipmentRelationships
type ShipmentRelationshipsContainers ¶
type ShipmentRelationshipsContainers struct {
Data []ShipmentRelationshipsContainersData `json:"data,omitempty"`
}
ShipmentRelationshipsContainers struct for ShipmentRelationshipsContainers
type ShipmentRelationshipsContainersData ¶
ShipmentRelationshipsContainersData struct for ShipmentRelationshipsContainersData
type ShipmentRelationshipsCustomer ¶
type ShipmentRelationshipsCustomer struct {
Data ShipmentRelationshipsCustomerData `json:"data,omitempty"`
}
ShipmentRelationshipsCustomer `unreleased`
type ShipmentRelationshipsCustomerData ¶
type ShipmentRelationshipsCustomerData struct { Type string `json:"type,omitempty"` Id string `json:"id,omitempty"` }
ShipmentRelationshipsCustomerData struct for ShipmentRelationshipsCustomerData
type ShipmentRelationshipsDestination ¶
type ShipmentRelationshipsDestination struct {
Data ShipmentRelationshipsDestinationData `json:"data,omitempty"`
}
ShipmentRelationshipsDestination struct for ShipmentRelationshipsDestination
type ShipmentRelationshipsDestinationData ¶
type ShipmentRelationshipsDestinationData struct { Type string `json:"type"` Id string `json:"id"` }
ShipmentRelationshipsDestinationData struct for ShipmentRelationshipsDestinationData
type ShipmentRelationshipsDestinationTerminal ¶ added in v1.2.1
type ShipmentRelationshipsDestinationTerminal struct { Type string `json:"type,omitempty"` Id string `json:"id,omitempty"` }
ShipmentRelationshipsDestinationTerminal struct for ShipmentRelationshipsDestinationTerminal
type ShipmentRelationshipsPodTerminal ¶
type ShipmentRelationshipsPodTerminal struct { Type string `json:"type,omitempty"` Id string `json:"id,omitempty"` }
ShipmentRelationshipsPodTerminal struct for ShipmentRelationshipsPodTerminal
type ShipmentRelationshipsPortOfLading ¶
type ShipmentRelationshipsPortOfLading struct {
Data ShipmentRelationshipsPortOfLadingData `json:"data,omitempty"`
}
ShipmentRelationshipsPortOfLading struct for ShipmentRelationshipsPortOfLading
type ShipmentRelationshipsPortOfLadingData ¶
type ShipmentRelationshipsPortOfLadingData struct { Type string `json:"type"` Id string `json:"id"` }
ShipmentRelationshipsPortOfLadingData struct for ShipmentRelationshipsPortOfLadingData
type ShipmentsApiService ¶
type ShipmentsApiService service
ShipmentsApiService ShipmentsApi service
func (*ShipmentsApiService) GetShipmentId ¶
func (a *ShipmentsApiService) GetShipmentId(ctx _context.Context, id string, localVarOptionals *GetShipmentIdOpts) (InlineResponse2001, *_nethttp.Response, error)
GetShipmentId Get a shipment Retrieves the details of an existing shipment. You need only supply the unique shipment `id` that was returned upon `tracking_request` creation.
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param id Shipment Id
- @param optional nil or *GetShipmentIdOpts - Optional Parameters:
- @param "Include" (optional.String) - Comma delimited list of relations to include
@return InlineResponse2001
func (*ShipmentsApiService) GetShipments ¶
func (a *ShipmentsApiService) GetShipments(ctx _context.Context, localVarOptionals *GetShipmentsOpts) (InlineResponse200, *_nethttp.Response, error)
GetShipments List shipments Returns a list of your shipments. The shipments are returned sorted by creation date, with the most recent shipments appearing first. This api will return all shipments associated with the account. Shipments created via the `tracking_request` API aswell as the ones added via the dashboard will be retuned via this endpoint.
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param optional nil or *GetShipmentsOpts - Optional Parameters:
- @param "PageNumber" (optional.Int32) -
- @param "PageSize" (optional.Int32) -
- @param "Q" (optional.String) - Search shipments by master bill of lading, reference number, or container number.
- @param "Include" (optional.String) - Comma delimited list of relations to include
- @param "Number" (optional.String) - Search shipments by the original request tracking `request_number`
@return InlineResponse200
type ShippingLine ¶
type ShippingLine struct { Id string `json:"id"` Attributes ShippingLineAttributes `json:"attributes"` Type string `json:"type"` }
ShippingLine struct for ShippingLine
type ShippingLineAttributes ¶
type ShippingLineAttributes struct { Scac string `json:"scac"` Name string `json:"name"` ShortName string `json:"short_name"` BillOfLadingTrackingSupport bool `json:"bill_of_lading_tracking_support"` BookingNumberTrackingSupport bool `json:"booking_number_tracking_support"` ContainerNumberTrackingSupport bool `json:"container_number_tracking_support"` }
ShippingLineAttributes struct for ShippingLineAttributes
type ShippingLinesApiService ¶ added in v1.1.0
type ShippingLinesApiService service
ShippingLinesApiService ShippingLinesApi service
func (*ShippingLinesApiService) GetShippingLines ¶ added in v1.1.0
func (a *ShippingLinesApiService) GetShippingLines(ctx _context.Context, localVarOptionals *GetShippingLinesOpts) (InlineResponse20012, *_nethttp.Response, error)
GetShippingLines Shipping Lines Return a list of shipping lines supported by Terminal49. N.B. There is no pagination for this endpoint.
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param optional nil or *GetShippingLinesOpts - Optional Parameters:
- @param "Body" (optional.Map[string]interface{}) -
@return InlineResponse20012
func (*ShippingLinesApiService) GetShippingLinesId ¶ added in v1.1.0
func (a *ShippingLinesApiService) GetShippingLinesId(ctx _context.Context, id string) (InlineResponse20013, *_nethttp.Response, error)
GetShippingLinesId Get a single shipping line Return the details of a single shipping line.
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param id
@return InlineResponse20013
type Terminal ¶
type Terminal struct { Id string `json:"id,omitempty"` Relationships TerminalRelationships `json:"relationships"` Attributes TerminalAttributes `json:"attributes"` Type string `json:"type,omitempty"` }
Terminal struct for Terminal
type TerminalAttributes ¶
type TerminalAttributes struct { Name string `json:"name"` Nickname string `json:"nickname,omitempty"` // CBP FIRMS Code or CBS Sublocation Code FirmsCode string `json:"firms_code,omitempty"` }
TerminalAttributes struct for TerminalAttributes
type TerminalFee ¶
type TerminalFee struct { Type string `json:"type"` // The fee amount in USD Amount float32 `json:"amount"` }
TerminalFee struct for TerminalFee
type TerminalHold ¶
type TerminalHold struct { Name string `json:"name"` Status string `json:"status"` // Text description from the terminal (if any) Description string `json:"description,omitempty"` }
TerminalHold struct for TerminalHold
type TerminalRelationships ¶
type TerminalRelationships struct {
Port TerminalRelationshipsPort `json:"port"`
}
TerminalRelationships struct for TerminalRelationships
type TerminalRelationshipsPort ¶
type TerminalRelationshipsPort struct {
Data TerminalRelationshipsPortData `json:"data,omitempty"`
}
TerminalRelationshipsPort struct for TerminalRelationshipsPort
type TerminalRelationshipsPortData ¶
type TerminalRelationshipsPortData struct { Id string `json:"id,omitempty"` Type string `json:"type,omitempty"` }
TerminalRelationshipsPortData struct for TerminalRelationshipsPortData
type TrackingRequest ¶
type TrackingRequest struct { Id string `json:"id"` Type string `json:"type"` Attributes TrackingRequestAttributes `json:"attributes,omitempty"` Relationships TrackingRequestRelationships `json:"relationships,omitempty"` }
TrackingRequest struct for TrackingRequest
type TrackingRequestAttributes ¶
type TrackingRequestAttributes struct { RequestNumber string `json:"request_number"` RefNumbers []string `json:"ref_numbers,omitempty"` Tags []string `json:"tags,omitempty"` Status string `json:"status"` // If the tracking request has failed, or is currently failing, the last reason we were unable to complete the request FailedReason *string `json:"failed_reason,omitempty"` RequestType string `json:"request_type"` Scac string `json:"scac"` CreatedAt time.Time `json:"created_at"` IsRetrying bool `json:"is_retrying,omitempty"` // How many times T49 has attempted to get the shipment from the shipping line RetryCount int32 `json:"retry_count,omitempty"` }
TrackingRequestAttributes struct for TrackingRequestAttributes
type TrackingRequestRelationships ¶
type TrackingRequestRelationships struct {
TrackedObject TrackingRequestRelationshipsTrackedObject `json:"tracked_object,omitempty"`
}
TrackingRequestRelationships struct for TrackingRequestRelationships
type TrackingRequestRelationshipsTrackedObject ¶ added in v1.0.8
type TrackingRequestRelationshipsTrackedObject struct {
Data TrackingRequestRelationshipsTrackedObjectData `json:"data,omitempty"`
}
TrackingRequestRelationshipsTrackedObject struct for TrackingRequestRelationshipsTrackedObject
type TrackingRequestRelationshipsTrackedObjectData ¶ added in v1.0.8
type TrackingRequestRelationshipsTrackedObjectData struct { Id string `json:"id,omitempty"` Type string `json:"type,omitempty"` }
TrackingRequestRelationshipsTrackedObjectData struct for TrackingRequestRelationshipsTrackedObjectData
type TrackingRequestsApiService ¶
type TrackingRequestsApiService service
TrackingRequestsApiService TrackingRequestsApi service
func (*TrackingRequestsApiService) GetTrackRequestById ¶
func (a *TrackingRequestsApiService) GetTrackRequestById(ctx _context.Context, id string, localVarOptionals *GetTrackRequestByIdOpts) (InlineResponse2003, *_nethttp.Response, error)
GetTrackRequestById Get a single tracking request Get the details and status of an existing tracking request.
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param id Tracking Request ID
- @param optional nil or *GetTrackRequestByIdOpts - Optional Parameters:
- @param "Include" (optional.String) - Comma delimited list of relations to include. 'tracked_object' is included by default.
@return InlineResponse2003
func (*TrackingRequestsApiService) GetTrackingRequests ¶
func (a *TrackingRequestsApiService) GetTrackingRequests(ctx _context.Context, localVarOptionals *GetTrackingRequestsOpts) (InlineResponse2002, *_nethttp.Response, error)
GetTrackingRequests List tracking requests Returns a list of your tracking requests. The trackig requests are returned sorted by creation date, with the most recent tracking request appearing first.
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param optional nil or *GetTrackingRequestsOpts - Optional Parameters:
- @param "Q" (optional.String) - A search term to be applied against request_number and reference_numbers.
- @param "FilterStatus" (optional.String) - filter by `status`
- @param "FilterScac" (optional.String) - filter by shipping line `scac`
- @param "FilterCreatedAtStart" (optional.Time) - filter by tracking_requests `created_at` after a certain ISO8601 timestamp
- @param "FilterCreatedAtEnd" (optional.Time) - filter by tracking_requests `created_at` before a certain ISO8601 timestamp
- @param "Include" (optional.String) - Comma delimited list of relations to include. 'tracked_object' is included by default.
- @param "PageNumber" (optional.Int32) -
- @param "PageSize" (optional.Int32) -
- @param "RequestNumber" (optional.String) - filter by tracking_requests `request_number`
@return InlineResponse2002
func (*TrackingRequestsApiService) PostTrack ¶
func (a *TrackingRequestsApiService) PostTrack(ctx _context.Context, localVarOptionals *PostTrackOpts) (InlineResponse201, *_nethttp.Response, error)
PostTrack Create a tracking request To track an ocean shipment, you create a new tracking request. Two attributes are required to track a shipment. A `bill of lading/booking number` and a shipping line `SCAC`. Once a tracking request is created we will attempt to fetch the shipment details and it's related containers from the shipping line. If the attempt is successful we will create in new shipment object including any related container objects. We will send a `tracking_Request.succeeded` webhook notification to your webhooks. If the attempt to fetch fails then we will send a `tracking_Request.failed` webhook notification to your `webhooks`. A `tracking_Request.succeeded` or `tracking_Request.failed` webhook notificaiton will only be sent if you have atleast one active webhook.
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param optional nil or *PostTrackOpts - Optional Parameters:
- @param "InlineObject" (optional.Interface of InlineObject) -
@return InlineResponse201
type TrackingRequestsData ¶
type TrackingRequestsData struct { Attributes TrackingRequestsDataAttributes `json:"attributes,omitempty"` Type string `json:"type"` }
TrackingRequestsData struct for TrackingRequestsData
type TrackingRequestsDataAttributes ¶
type TrackingRequestsDataAttributes struct { // The type of document number to be supplied. Container number support is currently in BETA. RequestType string `json:"request_type"` RequestNumber string `json:"request_number"` Scac string `json:"scac"` // Optional list of reference numbers to be added to the shipment when tracking request completes RefNumbers []string `json:"ref_numbers,omitempty"` // Optional list of tags to be added to the shipment when tracking request completes ShipmentTags []string `json:"shipment_tags,omitempty"` }
TrackingRequestsDataAttributes struct for TrackingRequestsDataAttributes
type TransportEvent ¶
type TransportEvent struct { Id string `json:"id"` Type string `json:"type"` Attributes TransportEventAttributes `json:"attributes,omitempty"` Relationships TransportEventRelationships `json:"relationships,omitempty"` }
TransportEvent struct for TransportEvent
type TransportEventAttributes ¶
type TransportEventAttributes struct { Event string `json:"event,omitempty"` VoyageNumber *string `json:"voyage_number,omitempty"` Timestamp *time.Time `json:"timestamp,omitempty"` // IANA tz Timezone *string `json:"timezone,omitempty"` // UNLOCODE of the event location LocationLocode *string `json:"location_locode,omitempty"` CreatedAt time.Time `json:"created_at,omitempty"` }
TransportEventAttributes struct for TransportEventAttributes
type TransportEventRelationships ¶
type TransportEventRelationships struct { Shipment TrackingRequestRelationshipsTrackedObject `json:"shipment,omitempty"` Location TransportEventRelationshipsLocation `json:"location,omitempty"` Vessel TransportEventRelationshipsVessel `json:"vessel,omitempty"` Terminal TransportEventRelationshipsTerminal `json:"terminal,omitempty"` Container TransportEventRelationshipsContainer `json:"container,omitempty"` }
TransportEventRelationships struct for TransportEventRelationships
type TransportEventRelationshipsContainer ¶
type TransportEventRelationshipsContainer struct {
Data TransportEventRelationshipsContainerData `json:"data,omitempty"`
}
TransportEventRelationshipsContainer struct for TransportEventRelationshipsContainer
type TransportEventRelationshipsContainerData ¶
type TransportEventRelationshipsContainerData struct { Id string `json:"id,omitempty"` Type string `json:"type,omitempty"` }
TransportEventRelationshipsContainerData struct for TransportEventRelationshipsContainerData
type TransportEventRelationshipsLocation ¶
type TransportEventRelationshipsLocation struct {
Data TransportEventRelationshipsLocationData `json:"data,omitempty"`
}
TransportEventRelationshipsLocation struct for TransportEventRelationshipsLocation
type TransportEventRelationshipsLocationData ¶ added in v1.0.3
type TransportEventRelationshipsLocationData struct { Id string `json:"id,omitempty"` Type string `json:"type,omitempty"` }
TransportEventRelationshipsLocationData struct for TransportEventRelationshipsLocationData
type TransportEventRelationshipsTerminal ¶
type TransportEventRelationshipsTerminal struct {
Data TransportEventRelationshipsTerminalData `json:"data,omitempty"`
}
TransportEventRelationshipsTerminal struct for TransportEventRelationshipsTerminal
type TransportEventRelationshipsTerminalData ¶
type TransportEventRelationshipsTerminalData struct { Id string `json:"id,omitempty"` Type string `json:"type,omitempty"` }
TransportEventRelationshipsTerminalData struct for TransportEventRelationshipsTerminalData
type TransportEventRelationshipsVessel ¶
type TransportEventRelationshipsVessel struct {
Data TransportEventRelationshipsVesselData `json:"data,omitempty"`
}
TransportEventRelationshipsVessel struct for TransportEventRelationshipsVessel
type TransportEventRelationshipsVesselData ¶
type TransportEventRelationshipsVesselData struct { Id string `json:"id,omitempty"` Name string `json:"name,omitempty"` }
TransportEventRelationshipsVesselData struct for TransportEventRelationshipsVesselData
type Vessel ¶
type Vessel struct { Id string `json:"id,omitempty"` Type string `json:"type,omitempty"` Attributes VesselAttributes `json:"attributes,omitempty"` }
Vessel struct for Vessel
type VesselAttributes ¶
type VesselAttributes struct { Name string `json:"name,omitempty"` Imo string `json:"imo,omitempty"` Mmsi string `json:"mmsi,omitempty"` }
VesselAttributes struct for VesselAttributes
type Webhook ¶
type Webhook struct { Id string `json:"id"` Type string `json:"type"` Attributes WebhookAttributes `json:"attributes,omitempty"` }
Webhook struct for Webhook
type WebhookAttributes ¶
type WebhookAttributes struct { // https end point Url string `json:"url"` // whether the webhook will be delivered when events are triggered Active bool `json:"active"` Events []string `json:"events"` // A random token that will sign all delivered webhooks Secret string `json:"secret"` Headers *[]WebhookAttributesHeaders `json:"headers,omitempty"` }
WebhookAttributes struct for WebhookAttributes
type WebhookAttributesHeaders ¶ added in v1.1.0
type WebhookAttributesHeaders struct { Name string `json:"name,omitempty"` Value string `json:"value,omitempty"` }
WebhookAttributesHeaders struct for WebhookAttributesHeaders
type WebhookNotification ¶
type WebhookNotification struct { Id string `json:"id,omitempty"` Type string `json:"type,omitempty"` Attributes WebhookNotificationAttributes `json:"attributes,omitempty"` Relationships WebhookNotificationRelationships `json:"relationships,omitempty"` }
WebhookNotification struct for WebhookNotification
type WebhookNotificationAttributes ¶
type WebhookNotificationAttributes struct { Event string `json:"event"` // Whether the notification has been delivered to the webhook endpoint DeliveryStatus string `json:"delivery_status"` CreatedAt string `json:"created_at"` }
WebhookNotificationAttributes struct for WebhookNotificationAttributes
type WebhookNotificationRelationships ¶
type WebhookNotificationRelationships struct { Webhook WebhookNotificationRelationshipsWebhook `json:"webhook"` ReferenceObject WebhookNotificationRelationshipsReferenceObject `json:"reference_object,omitempty"` }
WebhookNotificationRelationships struct for WebhookNotificationRelationships
type WebhookNotificationRelationshipsReferenceObject ¶
type WebhookNotificationRelationshipsReferenceObject struct {
Data WebhookNotificationRelationshipsReferenceObjectData `json:"data,omitempty"`
}
WebhookNotificationRelationshipsReferenceObject struct for WebhookNotificationRelationshipsReferenceObject
type WebhookNotificationRelationshipsReferenceObjectData ¶
type WebhookNotificationRelationshipsReferenceObjectData struct { Id string `json:"id,omitempty"` Type string `json:"type,omitempty"` }
WebhookNotificationRelationshipsReferenceObjectData struct for WebhookNotificationRelationshipsReferenceObjectData
type WebhookNotificationRelationshipsWebhook ¶
type WebhookNotificationRelationshipsWebhook struct {
Data WebhookNotificationRelationshipsWebhookData `json:"data,omitempty"`
}
WebhookNotificationRelationshipsWebhook struct for WebhookNotificationRelationshipsWebhook
type WebhookNotificationRelationshipsWebhookData ¶
type WebhookNotificationRelationshipsWebhookData struct { Id string `json:"id,omitempty"` Type string `json:"type,omitempty"` }
WebhookNotificationRelationshipsWebhookData struct for WebhookNotificationRelationshipsWebhookData
type WebhookNotificationsApiService ¶
type WebhookNotificationsApiService service
WebhookNotificationsApiService WebhookNotificationsApi service
func (*WebhookNotificationsApiService) GetWebhookNotificationId ¶
func (a *WebhookNotificationsApiService) GetWebhookNotificationId(ctx _context.Context, id string, localVarOptionals *GetWebhookNotificationIdOpts) (InlineResponse2006, *_nethttp.Response, error)
GetWebhookNotificationId Get a single webhook notification
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param id
- @param optional nil or *GetWebhookNotificationIdOpts - Optional Parameters:
- @param "Include" (optional.String) - Comma delimited list of relations to include.
@return InlineResponse2006
func (*WebhookNotificationsApiService) GetWebhookNotifications ¶
func (a *WebhookNotificationsApiService) GetWebhookNotifications(ctx _context.Context, localVarOptionals *GetWebhookNotificationsOpts) (InlineResponse2007, *_nethttp.Response, error)
GetWebhookNotifications List webhook notifications Return the list of webhook notifications. This can be useful for reconciling your data if your endpoint has been down.
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param optional nil or *GetWebhookNotificationsOpts - Optional Parameters:
- @param "PageNumber" (optional.Int32) -
- @param "PageSize" (optional.Int32) -
- @param "Include" (optional.String) - Comma delimited list of relations to include.
@return InlineResponse2007
type WebhooksApiService ¶
type WebhooksApiService service
WebhooksApiService WebhooksApi service
func (*WebhooksApiService) DeleteWebhooksId ¶
func (a *WebhooksApiService) DeleteWebhooksId(ctx _context.Context, id string) (*_nethttp.Response, error)
DeleteWebhooksId Delete a webhook Delete a webhook
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param id
func (*WebhooksApiService) GetWebhooks ¶
func (a *WebhooksApiService) GetWebhooks(ctx _context.Context, localVarOptionals *GetWebhooksOpts) (InlineResponse2005, *_nethttp.Response, error)
GetWebhooks List webhooks Get a list of all the webhooks
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param optional nil or *GetWebhooksOpts - Optional Parameters:
- @param "PageNumber" (optional.Int32) -
- @param "PageSize" (optional.Int32) -
@return InlineResponse2005
func (*WebhooksApiService) GetWebhooksId ¶
func (a *WebhooksApiService) GetWebhooksId(ctx _context.Context, id string) (InlineResponse2004, *_nethttp.Response, error)
GetWebhooksId Get single webhook Get the details of a single webhook
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param id
@return InlineResponse2004
func (*WebhooksApiService) PatchWebhooksId ¶
func (a *WebhooksApiService) PatchWebhooksId(ctx _context.Context, id string, localVarOptionals *PatchWebhooksIdOpts) (InlineResponse2004, *_nethttp.Response, error)
PatchWebhooksId Edit a webhook Update a single webhook
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param id
- @param optional nil or *PatchWebhooksIdOpts - Optional Parameters:
- @param "InlineObject1" (optional.Interface of InlineObject1) -
@return InlineResponse2004
func (*WebhooksApiService) PostWebhooks ¶
func (a *WebhooksApiService) PostWebhooks(ctx _context.Context, localVarOptionals *PostWebhooksOpts) (InlineResponse2004, *_nethttp.Response, error)
PostWebhooks Create a webhook You can configure a webhook via the API to be notified about events that happen in your Terminal49 account. These events can be realted to tracking_requests, shipments and containers. This is the recommended way tracking shipments and containers via the API. You should use this instead of polling our the API periodically.
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param optional nil or *PostWebhooksOpts - Optional Parameters:
- @param "InlineObject2" (optional.Interface of InlineObject2) -
@return InlineResponse2004
type WebhooksData ¶
type WebhooksData struct { Attributes WebhooksDataAttributes `json:"attributes"` Type string `json:"type"` }
WebhooksData struct for WebhooksData
type WebhooksDataAttributes ¶
type WebhooksDataAttributes struct { // The URL of the webhook endpoint. Url string `json:"url"` // The list of events to enable for this endpoint. You may specify `['*']` to enable all events. Events []string `json:"events,omitempty"` Active bool `json:"active"` // Optional custom headers to pass with each webhook invocation Headers []WebhooksDataAttributesHeaders `json:"headers,omitempty"` }
WebhooksDataAttributes struct for WebhooksDataAttributes
type WebhooksDataAttributesHeaders ¶
type WebhooksDataAttributesHeaders struct { // The name of the header. (Please note this will be auto-capitalized) Name string `json:"name,omitempty"` // The value to pass for the header Value string `json:"value,omitempty"` }
WebhooksDataAttributesHeaders struct for WebhooksDataAttributesHeaders
type WebhooksIdData ¶ added in v1.0.1
type WebhooksIdData struct { Attributes WebhooksIdDataAttributes `json:"attributes"` Type string `json:"type"` }
WebhooksIdData struct for WebhooksIdData
type WebhooksIdDataAttributes ¶ added in v1.0.1
type WebhooksIdDataAttributes struct { // The URL of the webhook endpoint. Url string `json:"url,omitempty"` // The list of events to enable for this endpoint. You may specify `['*']` to enable all events. Events []string `json:"events,omitempty"` Active bool `json:"active,omitempty"` // Optional custom headers to pass with each webhook invocation Headers []WebhooksIdDataAttributesHeaders `json:"headers,omitempty"` }
WebhooksIdDataAttributes struct for WebhooksIdDataAttributes
type WebhooksIdDataAttributesHeaders ¶ added in v1.0.1
type WebhooksIdDataAttributesHeaders struct { // The name of the header. (Please not this will be auto-capitalized) Name string `json:"name,omitempty"` // The value to pass for the header Value string `json:"value,omitempty"` }
WebhooksIdDataAttributesHeaders struct for WebhooksIdDataAttributesHeaders
Source Files ¶
- api_containers.go
- api_shipments.go
- api_shipping_lines.go
- api_tracking_requests.go
- api_webhook_notifications.go
- api_webhooks.go
- client.go
- configuration.go
- model__tracking_requests_data.go
- model__tracking_requests_data_attributes.go
- model__webhooks__id__data.go
- model__webhooks__id__data_attributes.go
- model__webhooks__id__data_attributes_headers.go
- model__webhooks_data.go
- model__webhooks_data_attributes.go
- model__webhooks_data_attributes_headers.go
- model_account.go
- model_account_attributes.go
- model_container.go
- model_container_attributes.go
- model_container_updated_event.go
- model_container_updated_event_attributes.go
- model_container_updated_event_relationships.go
- model_container_updated_event_relationships_container.go
- model_container_updated_event_relationships_container_data.go
- model_container_updated_event_relationships_terminal.go
- model_container_updated_event_relationships_terminal_data.go
- model_error.go
- model_error_source.go
- model_estimated_event.go
- model_estimated_event_attributes.go
- model_estimated_event_relationships.go
- model_estimated_event_relationships_shipment.go
- model_estimated_event_relationships_shipment_data.go
- model_estimated_event_relationships_vessel.go
- model_estimated_event_relationships_vessel_data.go
- model_inline_object.go
- model_inline_object_1.go
- model_inline_object_2.go
- model_inline_response_200.go
- model_inline_response_200_1.go
- model_inline_response_200_10.go
- model_inline_response_200_11.go
- model_inline_response_200_12.go
- model_inline_response_200_13.go
- model_inline_response_200_2.go
- model_inline_response_200_3.go
- model_inline_response_200_4.go
- model_inline_response_200_5.go
- model_inline_response_200_6.go
- model_inline_response_200_7.go
- model_inline_response_200_8.go
- model_inline_response_200_9.go
- model_inline_response_201.go
- model_inline_response_422.go
- model_links.go
- model_meta.go
- model_metro_area.go
- model_metro_area_attributes.go
- model_port.go
- model_port_attributes.go
- model_rail_terminal.go
- model_rail_terminal_relationships.go
- model_rail_terminal_relationships_metro_area.go
- model_rail_terminal_relationships_metro_area_data.go
- model_raw_event.go
- model_raw_event_attributes.go
- model_raw_event_relationships.go
- model_shipment.go
- model_shipment_attributes.go
- model_shipment_relationships.go
- model_shipment_relationships_containers.go
- model_shipment_relationships_containers_data.go
- model_shipment_relationships_customer.go
- model_shipment_relationships_customer_data.go
- model_shipment_relationships_destination.go
- model_shipment_relationships_destination_data.go
- model_shipment_relationships_destination_terminal.go
- model_shipment_relationships_pod_terminal.go
- model_shipment_relationships_port_of_lading.go
- model_shipment_relationships_port_of_lading_data.go
- model_shipping_line.go
- model_shipping_line_attributes.go
- model_terminal.go
- model_terminal_attributes.go
- model_terminal_fee.go
- model_terminal_hold.go
- model_terminal_relationships.go
- model_terminal_relationships_port.go
- model_terminal_relationships_port_data.go
- model_tracking_request.go
- model_tracking_request_attributes.go
- model_tracking_request_relationships.go
- model_tracking_request_relationships_tracked_object.go
- model_tracking_request_relationships_tracked_object_data.go
- model_transport_event.go
- model_transport_event_attributes.go
- model_transport_event_relationships.go
- model_transport_event_relationships_container.go
- model_transport_event_relationships_container_data.go
- model_transport_event_relationships_location.go
- model_transport_event_relationships_location_data.go
- model_transport_event_relationships_terminal.go
- model_transport_event_relationships_terminal_data.go
- model_transport_event_relationships_vessel.go
- model_transport_event_relationships_vessel_data.go
- model_vessel.go
- model_vessel_attributes.go
- model_webhook.go
- model_webhook_attributes.go
- model_webhook_attributes_headers.go
- model_webhook_notification.go
- model_webhook_notification_attributes.go
- model_webhook_notification_relationships.go
- model_webhook_notification_relationships_reference_object.go
- model_webhook_notification_relationships_reference_object_data.go
- model_webhook_notification_relationships_webhook.go
- model_webhook_notification_relationships_webhook_data.go
- response.go