{"definitions":{},"info":{"description":"powered by Flasgger","termsOfService":"/tos","title":"A swagger API","version":"0.0.1"},"paths":{"/v1/client/deposit":{"post":{"description":"    ","parameters":[{"in":"body","name":"body","required":true,"schema":{"properties":{"api_key":{"example":"YOUR_API_KEY","type":"string"},"price_in_usd":{"example":100,"type":"number"}},"required":["api_key","price_in_usd"],"type":"object"}}],"responses":{"200":{"data":{"amount_due_in_usd":0.0,"invoice_id":"","payment_options":[{"amount_due":"","currency":"BTC","payment_address":"","rate":0.0},{"amount_due":"","currency":"LTC","payment_address":"","rate":0.0}],"payment_url":"","status":"new"},"message":"successfully created crypto invoice","status":"success"}},"summary":"Create an Invoice for a Client.","tags":["Client"]}},"/v1/client/deposit/fetch":{"get":{"description":"    ","parameters":[{"in":"body","name":"body","required":true,"schema":{"properties":{"api_key":{"example":"YOUR_API_KEY","type":"string"},"invoice_id":{"example":"YOUR_INVOICE_ID","type":"string"}},"required":["api_key","invoice_id"],"type":"object"}}],"responses":{"200":{"data":{"amount_due_in_usd":0.0,"invoice_id":"","payment_options":[{"amount_due":"","currency":"BTC","payment_address":"","rate":0.0},{"amount_due":"","currency":"LTC","payment_address":"","rate":0.0}],"payment_url":"","status":"new"},"message":"invoice found","status":"success"}},"summary":"Fetch a Deposit for a Client.","tags":["Client"]}},"/v1/client/deposit/fetch/all":{"get":{"description":"    ","parameters":[{"in":"body","name":"body","required":true,"schema":{"properties":{"api_key":{"example":"YOUR_API_KEY","type":"string"}},"required":["api_key"],"type":"object"}}],"responses":{"200":{"data":{"invoice_id":{"amount_due_in_usd":0.0,"invoice_id":"","payment_options":[{"amount_due":"","currency":"BTC","payment_address":"","rate":0.0},{"amount_due":"","currency":"LTC","payment_address":"","rate":0.0}],"payment_url":"","status":"new"}},"message":"successfully fetched all invoice","status":"success"}},"summary":"Fetch all Deposits for a Client.","tags":["Client"]}},"/v1/client/information":{"get":{"description":"    ","parameters":[{"in":"body","name":"body","required":true,"schema":{"properties":{"api_key":{"example":"YOUR_API_KEY","type":"string"}},"required":["api_key"],"type":"object"}}],"responses":{"200":{"data":{"api_enabled":true,"api_key":"","client_balance":"0","client_id":"","client_name":"","client_role":""},"message":"successfully fetched client","status":"success"}},"summary":"Get Client Information.","tags":["Client"]}},"/v1/health":{"get":{"responses":{"200":{"status":"online"},"500":{"status":"offline"},"503":{"message":"error detailed here","status":"error"}},"summary":"Get Health Status.","tags":["Health"]}},"/v1/health/information":{"get":{"description":"    ","responses":{"200":{"api_last_down_message":"system maintenance in progress","api_last_down_reason":"maintenance","api_online":true,"api_up_since":"2024-05-01 10:00:00","api_ups_manifested_up":false,"api_ups_nonmanifested_up":true,"api_usps_manifested_up":false,"api_usps_nonmanifested_up":true,"api_version":"v1"},"500":{"status":"offline"},"503":{"message":"error detailed here","status":"error"}},"summary":"Get Health Information.","tags":["Health"]}},"/v1/{courier}/services":{"get":{"description":"    ","parameters":[{"example":"ups,usps,fedex,all","in":"path","name":"courier","required":true,"type":"string"},{"in":"body","name":"body","required":false,"schema":{"properties":{"api_key":{"example":"YOUR_API_KEY","type":"string"}},"type":"object"}}],"responses":{"200":{"description":"Success","examples":{"application/json":{"data":{"client_role":"default","courier":"courier_name","services":{"Express Shipping":{"manifested_cost":"25.00","standard_cost":"30.00"},"Standard Shipping":{"manifested_cost":"10.00","standard_cost":"15.00"}}},"message":"successfully fetched services","status":"success"}}}},"summary":"Get Services for a Courier.","tags":["Service"]}},"/v1/{courier}/trackings":{"get":{"description":"    ","parameters":[{"in":"path","name":"courier","required":true,"type":"string"},{"in":"body","name":"body","required":true,"schema":{"properties":{"api_key":{"example":"YOUR_API_KEY","type":"string"}},"required":["api_key"],"type":"object"}}],"responses":{"200":{"description":"All tracking info","examples":{"application/json":{"data":{"data":{"TRACKING_NUMBER_1":{"base64_encoded_pdf":"...","date_created":"2024-1-1 1:00:00","package_information":{"package_description":"","package_height":"","package_length":"","package_reference1":"","package_reference2":"","package_weight":"","package_weight_unit":"","package_width":""},"receiver_information":{"receiver_address1":"","receiver_address2":"","receiver_city":"","receiver_company":"","receiver_country":"","receiver_name":"","receiver_phone":"","receiver_state_province":"","receiver_zip_postal":""},"sender_information":{"sender_address1":"","sender_address2":"","sender_city":"","sender_company":"","sender_country":"","sender_name":"","sender_phone":"","sender_state_province":"","sender_zip_postal":""},"service_cost":"","service_courier":"","service_name":"","tracking_number":"YOUR_TRACKING_NUMBER"}},"message":"tracking numbers found","status":"success"},"message":"successfully fetched all tracking information","status":"success"}}},"404":{"description":"Not found","examples":{"application/json":{"message":"failed to fetch tracking: error detailed here","status":"error"}}},"500":{"description":"Server error","examples":{"application/json":{"message":"error detailed here","status":"error"}}}},"summary":"Get Trackings for a Courier.","tags":["Service"]}},"/v1/{courier}/{filetype}/create":{"post":{"description":"    ","parameters":[{"in":"path","name":"courier","required":true,"schema":{"example":"fedex","type":"string"}},{"in":"path","name":"filetype","required":true,"schema":{"example":"image","type":"string"}},{"in":"body","name":"body","required":true,"schema":{"properties":{"api_key":{"type":"string"},"idempotency_key":{"description":"Idempotency key. Used ONLY for manifested FedEx (manifested=true, courier=fedex); ignored for every other courier and for non-manifested FedEx. Must be 32 lowercase hex chars -- generate one with Python uuid.uuid4().hex. Reusing a key with a different request body returns 409.","example":"3f6b1c2a9d8e4f710a2b3c4d5e6f7081","type":"string"},"manifested":{"default":false,"type":"boolean"},"package":{"type":"object"},"receiver":{"type":"object"},"sender":{"type":"object"},"service_name":{"example":"FedEx Ground, United States","type":"string"},"valid_data":{"description":"Opaque blob from /validate; pass back verbatim.","type":"object"},"version":{"example":"uspsvpitneybowesv5","type":"string"}},"required":["api_key","service_name","sender","receiver","package"],"type":"object"}}],"responses":{"200":{"description":"Shipment created","examples":{"application/json":{"data":{"base64_encoded_image":"","tracking_number":"#"},"message":"successfully created shipment with tracking #","status":"success"}}},"404":{"description":"Not found","examples":{"application/json":{"message":"failed to create shipment: error detailed here","status":"error"}}},"409":{"description":"idempotency_key reused with a different request","examples":{"application/json":{"message":"idempotency_key reused with a different request","status":"error"}}},"500":{"description":"Server error","examples":{"application/json":{"message":"error detailed here","status":"error"}}}},"summary":"Generate a tracking number and label.","tags":["Shipments"]}},"/v1/{courier}/{filetype}/fetch":{"get":{"description":"    ","parameters":[{"in":"path","name":"courier","required":true,"type":"string"},{"in":"path","name":"filetype","required":true,"type":"string"}],"responses":{"200":{"description":"Success","examples":{"application/json":{"data":"Detailed example of a successful response","message":"success"}}},"400":{"description":"Bad request","examples":{"application/json":{"details":"Detailed example of a bad request","message":"error"}}},"404":{"description":"Not found","examples":{"application/json":{"details":"Detailed example of a not found error","message":"error"}}},"500":{"description":"Server error","examples":{"application/json":{"details":"Detailed example of a server error","message":"error"}}}},"summary":"Fetch a Shipment for a Courier.","tags":["Shipments"]}}},"swagger":"2.0"}
