{"openapi":"3.1.0","info":{"title":"Pickup API","description":"Pickup API reference for external system"},"servers":[{"url":"https://api.bring.com/pickup"}],"paths":{"/api/create":{"post":{"tags":["pickup-order-api-resource"],"summary":"Order a pickup","operationId":"pickup","parameters":[{"name":"X-MyBring-API-Uid","in":"header","description":"Mybring login ID","required":true,"schema":{"type":"string"}},{"name":"X-MyBring-API-Key","in":"header","description":"Your user's API key","required":true,"schema":{"type":"string"}},{"name":"X-Bring-Test-Indicator","in":"header","description":"A boolean value indicating whether this is a test or not","required":true,"schema":{"type":"boolean"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PickupOrderApiRequestDto"},"examples":{"Parcel pickup Norway":{"description":"Parcel pickup Norway","value":{"customerInformation":{"customerNumber":"************","companyName":"Norsk Bedrift AS"},"pickupAddress":{"street":"Testsvingen 12","postalCode":"0263","city":"OSLO","email":"norsk.bedrift@example.com","phoneNumber":"+4712345678","message":"Hentes på baksiden"},"pickupDate":"2015-12-03","pickupIsReadyAtTime":null,"pickupTimeZone":null,"countryCode":"NO","service":"PARCEL","pickupDetails":{"packages":{"count":2,"weightInGrams":1000},"pallets":{"count":1,"weightInGrams":15000},"postContainers":{"count":0}}}},"Parcel pickup International":{"description":"Parcel pickup International","value":{"customerInformation":{"customerNumber":"************","companyName":"Svensk Bedrift AS"},"pickupAddress":{"street":"Testsvingen 12","postalCode":"12000","city":"Stockholm","email":"svensk.bedrift@example.com","phoneNumber":"+46781234567","message":"Hentes på baksiden"},"pickupDate":"2015-12-03","pickupIsReadyAtTime":null,"pickupTimeZone":null,"countryCode":"SE","service":"PARCEL","pickupDetails":{"packages":{"count":2},"pallets":{"count":1},"weightInGrams":15000}}},"Groupage pickup":{"description":"Groupage pickup","value":{"customerInformation":{"customerNumber":"*******","companyName":"Norsk Bedrift AS"},"pickupAddress":{"street":"Testsvingen 12","postalCode":"0263","city":"OSLO","email":"norsk.bedrift@example.com","phoneNumber":"+4712345678","message":"Hentes på baksiden"},"pickupDate":"2015-12-03","pickupIsReadyAtTime":null,"pickupTimeZone":"Europe/Oslo","countryCode":"NO","service":"CARGO","pickupDetails":{"packages":{"count":2,"weightInGrams":1000,"volumeInDm3":40}}}}}},"application/xml":{"schema":{"$ref":"#/components/schemas/PickupOrderApiRequestDto"},"examples":{"Parcel pickup Norway":{"description":"Parcel pickup Norway","value":{"customerInformation":{"customerNumber":"************","companyName":"Norsk Bedrift AS"},"pickupAddress":{"street":"Testsvingen 12","postalCode":"0263","city":"OSLO","email":"norsk.bedrift@example.com","phoneNumber":"+4712345678","message":"Hentes på baksiden"},"pickupDate":"2015-12-03","pickupIsReadyAtTime":null,"pickupTimeZone":null,"countryCode":"NO","service":"PARCEL","pickupDetails":{"packages":{"count":2,"weightInGrams":1000},"pallets":{"count":1,"weightInGrams":15000},"postContainers":{"count":0}}}},"Parcel pickup International":{"description":"Parcel pickup International","value":{"customerInformation":{"customerNumber":"************","companyName":"Svensk Bedrift AS"},"pickupAddress":{"street":"Testsvingen 12","postalCode":"12000","city":"Stockholm","email":"svensk.bedrift@example.com","phoneNumber":"+46781234567","message":"Hentes på baksiden"},"pickupDate":"2015-12-03","pickupIsReadyAtTime":null,"pickupTimeZone":null,"countryCode":"SE","service":"PARCEL","pickupDetails":{"packages":{"count":2},"pallets":{"count":1},"weightInGrams":15000}}},"Groupage pickup":{"description":"Groupage pickup","value":{"customerInformation":{"customerNumber":"*******","companyName":"Norsk Bedrift AS"},"pickupAddress":{"street":"Testsvingen 12","postalCode":"0263","city":"OSLO","email":"norsk.bedrift@example.com","phoneNumber":"+4712345678","message":"Hentes på baksiden"},"pickupDate":"2015-12-03","pickupIsReadyAtTime":null,"pickupTimeZone":"Europe/Oslo","countryCode":"NO","service":"CARGO","pickupDetails":{"packages":{"count":2,"weightInGrams":1000,"volumeInDm3":40}}}}}}},"required":true},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"string"},"examples":{"Pickup Order Response":{"description":"Pickup Order Response","value":{"pickupConfirmation":{"status":"OK","earliestPickupDate":1720159200000,"latestPickupDate":1720188000000,"url":"https://www.mybring.com/order-pickup/receipt/xxxxxxxxx","packageNumber":"123456789012345678","isoFormattedEarliestPickupDateTime":"2024-05-27T08:00:00.000+00:00","isoFormattedLatestPickupDateTime":"2024-05-27T16:00:00.000+00:00"},"errors":null}}}},"application/xml":{"schema":{"type":"string"},"examples":{"Pickup Order Response":{"description":"Pickup Order Response","value":"<pickupOrderResponse>\n    <pickupConfirmation>\n        <status>OK</status>\n        <earliestPickupDate>2024-05-27T08:00:00+00:00</earliestPickupDate>\n        <latestPickupDate>2024-05-27T16:00:00+00:00</latestPickupDate>\n        <url>https://www.mybring.com/order-pickup/receipt/xxxxxxxxx</url>\n        <packageNumber>123456789012345678</packageNumber>\n    </pickupConfirmation>\n</pickupOrderResponse>\n"}}}}},"400":{"description":"Bad Request","content":{"application/xml;charset=UTF-8":{"schema":{"type":"array","items":{"type":"string"}},"examples":{"INVALID_PRODUCT_ID":{"$ref":"#/components/examples/INVALID_PRODUCT_ID"},"INVALID_COUNTRY_CODE":{"$ref":"#/components/examples/INVALID_COUNTRY_CODE"},"UNAUTHORIZED":{"$ref":"#/components/examples/UNAUTHORIZED"},"ILLEGAL_PRODUCT_FOR_COUNTRY":{"$ref":"#/components/examples/ILLEGAL_PRODUCT_FOR_COUNTRY"},"PICKUP_UNEXPECTED_ERROR":{"$ref":"#/components/examples/PICKUP_UNEXPECTED_ERROR"},"PICKUP_INPUT_ERROR":{"$ref":"#/components/examples/PICKUP_INPUT_ERROR"},"PICKUP_INVALID_POSTALCODE":{"$ref":"#/components/examples/PICKUP_INVALID_POSTALCODE"},"PICKUP_INVALID_CARGO_PARCEL_INFORMATION":{"$ref":"#/components/examples/PICKUP_INVALID_CARGO_PARCEL_INFORMATION"},"PICKUP_NOT_APPLICABLE_FOR_CUSTOMER":{"$ref":"#/components/examples/PICKUP_NOT_APPLICABLE_FOR_CUSTOMER"},"PICKUP_INVALID_TIME":{"$ref":"#/components/examples/PICKUP_INVALID_TIME"},"PICKUP_INVALID_DATE":{"$ref":"#/components/examples/PICKUP_INVALID_DATE"},"PICKUP_DATE_IN_PAST":{"$ref":"#/components/examples/PICKUP_DATE_IN_PAST"},"PICKUP_INVALID_WEIGHT":{"$ref":"#/components/examples/PICKUP_INVALID_WEIGHT"},"PICKUP_NEGATIVE_FIELD":{"$ref":"#/components/examples/PICKUP_NEGATIVE_FIELD"},"PICKUP_MISSING_COUNTRY_CODE":{"$ref":"#/components/examples/PICKUP_MISSING_COUNTRY_CODE"},"SPECIFIC_PICKUP_POINT_DETAILS_REQ":{"$ref":"#/components/examples/SPECIFIC_PICKUP_POINT_DETAILS_REQ"},"INVALID_PICKUP_COUNTRY":{"$ref":"#/components/examples/INVALID_PICKUP_COUNTRY"},"PICKUP_TIME_IN_PAST":{"$ref":"#/components/examples/PICKUP_TIME_IN_PAST"},"PICKUP_INVALID_CHARGEABLE_WEIGHT":{"$ref":"#/components/examples/PICKUP_INVALID_CHARGEABLE_WEIGHT"},"PICKUP_INVALID_MULTIPLE_WEIGHT":{"$ref":"#/components/examples/PICKUP_INVALID_MULTIPLE_WEIGHT"}}},"application/json":{"schema":{"type":"array","items":{"type":"string"}},"examples":{"INVALID_PRODUCT_ID":{"$ref":"#/components/examples/INVALID_PRODUCT_ID"},"INVALID_COUNTRY_CODE":{"$ref":"#/components/examples/INVALID_COUNTRY_CODE"},"UNAUTHORIZED":{"$ref":"#/components/examples/UNAUTHORIZED"},"ILLEGAL_PRODUCT_FOR_COUNTRY":{"$ref":"#/components/examples/ILLEGAL_PRODUCT_FOR_COUNTRY"},"PICKUP_UNEXPECTED_ERROR":{"$ref":"#/components/examples/PICKUP_UNEXPECTED_ERROR"},"PICKUP_INPUT_ERROR":{"$ref":"#/components/examples/PICKUP_INPUT_ERROR"},"PICKUP_INVALID_POSTALCODE":{"$ref":"#/components/examples/PICKUP_INVALID_POSTALCODE"},"PICKUP_INVALID_CARGO_PARCEL_INFORMATION":{"$ref":"#/components/examples/PICKUP_INVALID_CARGO_PARCEL_INFORMATION"},"PICKUP_NOT_APPLICABLE_FOR_CUSTOMER":{"$ref":"#/components/examples/PICKUP_NOT_APPLICABLE_FOR_CUSTOMER"},"PICKUP_INVALID_TIME":{"$ref":"#/components/examples/PICKUP_INVALID_TIME"},"PICKUP_INVALID_DATE":{"$ref":"#/components/examples/PICKUP_INVALID_DATE"},"PICKUP_DATE_IN_PAST":{"$ref":"#/components/examples/PICKUP_DATE_IN_PAST"},"PICKUP_INVALID_WEIGHT":{"$ref":"#/components/examples/PICKUP_INVALID_WEIGHT"},"PICKUP_NEGATIVE_FIELD":{"$ref":"#/components/examples/PICKUP_NEGATIVE_FIELD"},"PICKUP_MISSING_COUNTRY_CODE":{"$ref":"#/components/examples/PICKUP_MISSING_COUNTRY_CODE"},"SPECIFIC_PICKUP_POINT_DETAILS_REQ":{"$ref":"#/components/examples/SPECIFIC_PICKUP_POINT_DETAILS_REQ"},"INVALID_PICKUP_COUNTRY":{"$ref":"#/components/examples/INVALID_PICKUP_COUNTRY"},"PICKUP_TIME_IN_PAST":{"$ref":"#/components/examples/PICKUP_TIME_IN_PAST"},"PICKUP_INVALID_CHARGEABLE_WEIGHT":{"$ref":"#/components/examples/PICKUP_INVALID_CHARGEABLE_WEIGHT"},"PICKUP_INVALID_MULTIPLE_WEIGHT":{"$ref":"#/components/examples/PICKUP_INVALID_MULTIPLE_WEIGHT"}}}}}}}}},"components":{"schemas":{"CustomerInformationDto":{"type":"object","properties":{"customerNumber":{"type":"string"},"companyName":{"type":"string"}},"required":["companyName","customerNumber"],"xml":{"name":"customerInformation","namespace":"http://www.bring.no/booking/"}},"Packages":{"type":"object","properties":{"weightInGrams":{"type":"integer","format":"int32","description":"Applicable for parcel pickups in Norway and Nordics and required for cargo pickup"},"volumeInDm3":{"type":"number","description":"Applicable and required for cargo pickup"},"count":{"type":"integer","format":"int32","description":"For giving number of packages. Applicable for parcel pickups in Norway and Nordics and cargo pickup"}},"required":["count"],"xml":{"name":"packages","namespace":"http://www.bring.no/booking/"}},"Pallets":{"type":"object","properties":{"weightInGrams":{"type":"integer","format":"int32","description":"Applicable for parcel pickups in Norway and Nordics"},"count":{"type":"integer","format":"int32","description":"For giving number of pallets. Applicable for parcel pickups in Norway and Nordics"}},"required":["count"],"xml":{"name":"pallets","namespace":"http://www.bring.no/booking/"}},"PickUpDetails":{"type":"object","properties":{"numberOfPackages":{"type":"integer","format":"int32","deprecated":true,"description":"This is deprecated. Use packages and count instead"},"numberOfPostContainers":{"type":"integer","format":"int32","deprecated":true,"description":"This is deprecated. Use postContainers and count instead"},"numberOfPallets":{"type":"integer","format":"int32","deprecated":true,"description":"This is deprecated. Use pallets and count instead"},"weightInGrams":{"type":"integer","format":"int32","description":"Applicable for pickup in Nordics"},"volumeInDm3":{"type":"number","deprecated":true,"description":"This is deprecated. Use packages and volumeInDm3 instead"},"packages":{"$ref":"#/components/schemas/Packages"},"pallets":{"$ref":"#/components/schemas/Pallets"},"postContainers":{"$ref":"#/components/schemas/PostContainers"}},"xml":{"name":"pickupDetails","namespace":"http://www.bring.no/booking/"}},"PickupAddressDto":{"type":"object","properties":{"street":{"type":"string"},"postalCode":{"type":"string"},"city":{"type":"string"},"email":{"type":"string","maxLength":60},"phoneNumber":{"type":"string"},"contactName":{"type":"string"},"message":{"type":"string","description":"Generic message to the driver","xml":{"name":"messageToDriver"}},"deliveryInstruction":{"type":"string","description":"Delivery instruction to the driver","xml":{"name":"deliveryInstructionToDriver"}}},"required":["city","email","phoneNumber","postalCode","street"],"xml":{"name":"pickupAddress","namespace":"http://www.bring.no/booking/"}},"PickupOrderApiRequestDto":{"type":"object","properties":{"testIndicator":{"type":"boolean","deprecated":true,"description":"Deprecated, use HTTP header instead. For test orders, set this to true","xml":{"attribute":true}},"service":{"type":"string","description":"The pickup service you want to book","enum":["PARCEL","CARGO"]},"customerInformation":{"$ref":"#/components/schemas/CustomerInformationDto"},"pickupAddress":{"$ref":"#/components/schemas/PickupAddressDto"},"pickupDate":{"type":"string"},"pickupIsReadyAtTime":{"type":"string","description":"Currently not in use"},"pickupTimeZone":{"type":"string"},"countryCode":{"type":"string","description":"Two-letter ISO-3166-1 country code"},"pickupDetails":{"$ref":"#/components/schemas/PickUpDetails"}},"required":["countryCode","customerInformation","pickupAddress","pickupDate","service"],"xml":{"name":"pickupOrderRequest","namespace":"http://www.bring.no/booking/"}},"PostContainers":{"type":"object","properties":{"weightInGrams":{"type":"integer","format":"int32","description":"Applicable for parcel pickups in Norway"},"count":{"type":"integer","format":"int32","description":"For giving number of postContainers. Applicable for parcel pickups in Norway"}},"required":["count"],"xml":{"name":"postContainers","namespace":"http://www.bring.no/booking/"}}},"examples":{"INVALID_PRODUCT_ID":{"value":{"errors":[{"uniqueId":"3ba6fb7e-d50d-4ddd-8acb-8c2c91e6f535","code":"BOOK-INPUT-020","messages":[{"lang":"en","message":"Invalid product ID"}]}]}},"INVALID_COUNTRY_CODE":{"value":{"errors":[{"uniqueId":"00f1aef5-f3d7-4379-b3f5-8e24cddea754","code":"BOOK-INPUT-028","messages":[{"lang":"en","message":"Invalid country code"}]}]}},"UNAUTHORIZED":{"value":{"errors":[{"uniqueId":"310aace5-6899-4f9a-851a-248e69bcefa7","code":"BOOK-AUTHORIZATION-001","messages":[{"lang":"en","message":"Your user is not authorized to perform this action"}]}]}},"ILLEGAL_PRODUCT_FOR_COUNTRY":{"value":{"errors":[{"uniqueId":"4478c2b8-82f6-4135-8a72-3119686d8ebc","code":"BOOK-INPUT-022","messages":[{"lang":"en","message":"Illegal product for country"}]}]}},"PICKUP_UNEXPECTED_ERROR":{"value":{"errors":[{"uniqueId":"f0ca1d3a-3cf0-47f1-bc8e-db63031fb47d","code":"PICKUP-INTERNAL-001","messages":[{"lang":"en","message":"An unexpected error occurred"}]}]}},"PICKUP_INPUT_ERROR":{"value":{"errors":[{"uniqueId":"2480760c-9ed2-4237-bc9c-6741142559e1","code":"PICKUP-INPUT-001","messages":[{"lang":"en","message":"Error with input in pickupOrder"}]}]}},"PICKUP_INVALID_POSTALCODE":{"value":{"errors":[{"uniqueId":"6866f928-bb18-4ddf-863b-6cb3de64cc4a","code":"PICKUP-INPUT-002","messages":[{"lang":"en","message":"Postal code must be given and be valid"}]}]}},"PICKUP_INVALID_CARGO_PARCEL_INFORMATION":{"value":{"errors":[{"uniqueId":"3844263b-eb5a-48a0-80f1-af0dc9080e79","code":"PICKUP-INPUT-003","messages":[{"lang":"en","message":"Cargo customer must provide cargoInformation element. Parcel customer must provide parcelsInformation element"}]}]}},"PICKUP_NOT_APPLICABLE_FOR_CUSTOMER":{"value":{"errors":[{"uniqueId":"b756651e-5f41-44ab-9aa9-4f17f7e4f332","code":"PICKUP-INPUT-004","messages":[{"lang":"en","message":"This customer number cannot be used to order Pickup"}]}]}},"PICKUP_INVALID_TIME":{"value":{"errors":[{"uniqueId":"128bc308-12fa-4fda-8cb3-1188944da413","code":"PICKUP-INPUT-005","messages":[{"lang":"en","message":"You must specify pickupIsReadyAtTime element HH:mm:ss"}]}]}},"PICKUP_INVALID_DATE":{"value":{"errors":[{"uniqueId":"cfcebbf3-890c-4bc2-aa41-b4684d97bf21","code":"PICKUP-INPUT-006","messages":[{"lang":"en","message":"You must specify pickupDate element yyyy-MM-dd"}]}]}},"PICKUP_DATE_IN_PAST":{"value":{"errors":[{"uniqueId":"9d28a5dd-f4a5-4d8a-92c3-4e86183a1257","code":"PICKUP-INPUT-007","messages":[{"lang":"en","message":"Pickup date must be in the future"}]}]}},"PICKUP_INVALID_WEIGHT":{"value":{"errors":[{"uniqueId":"3c1f8ef2-581c-45d0-b78c-935643c0f5a4","code":"PICKUP-INPUT-008","messages":[{"lang":"en","message":"weightInGrams is required, and must be an integer larger than zero"}]}]}},"PICKUP_NEGATIVE_FIELD":{"value":{"errors":[{"uniqueId":"45b91102-789b-4b93-b302-753bbaa740b3","code":"PICKUP-INPUT-009","messages":[{"lang":"en","message":"Must be an integer larger than zero"}]}]}},"PICKUP_MISSING_COUNTRY_CODE":{"value":{"errors":[{"uniqueId":"fd6701b3-0400-4781-a007-1461b95b7b55","code":"PICKUP-INPUT-010","messages":[{"lang":"en","message":"Country code is required"}]}]}},"SPECIFIC_PICKUP_POINT_DETAILS_REQ":{"value":{"errors":[{"uniqueId":"cafb6ec7-9755-44f5-8e31-81f8dcbb7c2d","code":"PICKUP-INPUT-011","messages":[{"lang":"en","message":"Both Pickup Point ID and Country Code is Required"}]}]}},"INVALID_PICKUP_COUNTRY":{"value":{"errors":[{"uniqueId":"41a58706-90e3-437a-b067-cfcd553f8717","code":"PICKUP-INPUT-012","messages":[{"lang":"en","message":"Selected pickup point should be in recipient country"}]}]}},"PICKUP_TIME_IN_PAST":{"value":{"errors":[{"uniqueId":"34e0a91c-1ef0-437b-828a-65b28ca7cfe5","code":"PICKUP-INPUT-013","messages":[{"lang":"en","message":"Combination pickupIsReadyAtTime and pickupDate must be in the future"}]}]}},"PICKUP_INVALID_CHARGEABLE_WEIGHT":{"value":{"errors":[{"uniqueId":"6dbbdba9-d27b-4464-a8e8-d5342a6b1d2a","code":"PICKUP-INPUT-015","messages":[{"lang":"en","message":"Chargeable weight must be below groupage max weight limit"}]}]}},"PICKUP_INVALID_MULTIPLE_WEIGHT":{"value":{"errors":[{"uniqueId":"0666d40d-24b4-42c5-accd-f725aee44acd","code":"PICKUP-INPUT-016","messages":[{"lang":"en","message":"Must either have weightInGrams in pickupDetails, or on package or pallets level. Can not have both"}]}]}}}}}