{"openapi":"3.1.0","info":{"title":"Flow Dealers API","description":"The Flow Dealers API lets verified coin and collectibles dealers search the wholesale marketplace, manage\ntheir own listings, make and answer offers, and read their orders.\n\nAuthenticate with an API key in the Authorization header: `Authorization: Bearer fd_live_...`.\nOwners and admins on the Pro or Enterprise plans create keys at https://www.flowdealers.com/settings/api-keys.\nEach key allows 120 requests per 60 seconds.\nOver the limit, the API returns 429 with a Retry-After header.\n\nMoney is in integer cents (USD). Timestamps are ISO 8601. Errors have the shape `{ code, message }`,\nplus `issues` when the request fails validation.","version":"1.0.0"},"servers":[{"url":"https://api.flowauctions.com/dealers/v1"}],"tags":[{"name":"Account"},{"name":"Listings"},{"name":"Your listings"},{"name":"Offers"},{"name":"Orders"}],"externalDocs":{"url":"https://www.flowdealers.com/developers"},"paths":{"/me":{"get":{"operationId":"me","summary":"Check your API key","description":"Returns the organization and key that the request is authenticated as.","tags":["Account"],"security":[{"ApiKey":["read"]}],"parameters":[],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"organization":{"$ref":"#/components/schemas/Organization"},"apiKey":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"name":{"anyOf":[{"type":"string"},{"type":"null"}]},"expiresAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"},{"type":"null"}]},"scopes":{"description":"read allows GET requests; write allows changes.","type":"array","items":{"type":"string","enum":["read","write"]}}},"required":["id","name","expiresAt","scopes"],"additionalProperties":false},"rateLimit":{"type":"object","properties":{"maxRequests":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"windowSeconds":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["maxRequests","windowSeconds"],"additionalProperties":false}},"required":["organization","apiKey","rateLimit"],"additionalProperties":false}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/listings":{"get":{"operationId":"searchListings","summary":"Search the marketplace","description":"Listings that other verified dealers can buy now: unsold, not delisted, and in stock.","tags":["Listings"],"security":[{"ApiKey":["read"]}],"parameters":[{"in":"query","name":"q","schema":{"type":"string","minLength":1,"maxLength":200}},{"in":"query","name":"categoryId","schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"}},{"in":"query","name":"sellerId","schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"}},{"in":"query","name":"gradingService","schema":{"type":"string"}},{"in":"query","name":"grade","schema":{"type":"string"}},{"in":"query","name":"minPriceInCents","schema":{"type":"integer","minimum":0,"maximum":9007199254740991}},{"in":"query","name":"maxPriceInCents","schema":{"type":"integer","minimum":1,"maximum":9007199254740991}},{"in":"query","name":"sort","schema":{"default":"newest","type":"string","enum":["newest","oldest","price_asc","price_desc"]}},{"in":"query","name":"page","schema":{"description":"Page number, starting at 1.","default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"in":"query","name":"limit","schema":{"description":"Results per page, 1 to 100.","default":20,"type":"integer","minimum":1,"maximum":100}}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Listing"}},"page":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"limit":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"hasMore":{"description":"True when another page follows this one.","type":"boolean"}},"required":["items","page","limit","hasMore"],"additionalProperties":false}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/listings/{id}":{"get":{"operationId":"getListing","summary":"Get a marketplace listing","tags":["Listings"],"security":[{"ApiKey":["read"]}],"parameters":[{"in":"path","name":"id","schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Listing"}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/me/listings":{"get":{"operationId":"listOwnListings","summary":"List your listings","description":"Your organization's listings, including cost and sold or delisted ones.","tags":["Your listings"],"security":[{"ApiKey":["read"]}],"parameters":[{"in":"query","name":"q","schema":{"type":"string","minLength":1,"maxLength":200}},{"in":"query","name":"status","schema":{"default":"all","type":"string","enum":["active","sold","all"]}},{"in":"query","name":"sort","schema":{"default":"newest","type":"string","enum":["newest","oldest","price_asc","price_desc"]}},{"in":"query","name":"page","schema":{"description":"Page number, starting at 1.","default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"in":"query","name":"limit","schema":{"description":"Results per page, 1 to 100.","default":20,"type":"integer","minimum":1,"maximum":100}}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/OwnListing"}},"page":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"limit":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"hasMore":{"description":"True when another page follows this one.","type":"boolean"}},"required":["items","page","limit","hasMore"],"additionalProperties":false}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}},"post":{"operationId":"createListing","summary":"Create a listing","description":"Lists a coin on the marketplace. Your organization must be a verified dealer. Photos are added in the Flow Dealers app.","tags":["Your listings"],"security":[{"ApiKey":["write"]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":200},"description":{"description":"Plain text. Each line becomes a paragraph.","type":"string","maxLength":20000},"priceInCents":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"costInCents":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"quantity":{"default":1,"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"sku":{"type":"string","maxLength":100},"number":{"type":"string","maxLength":100},"categoryId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"gradingService":{"type":"string","maxLength":50},"grade":{"type":"string","maxLength":50},"certificateNumber":{"type":"string","maxLength":50},"attributes":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"null"}]}},"shippingMethod":{"default":"flat_rate","type":"string","enum":["flat_rate","free","calculated","pickup_only"]},"shippingCostInCents":{"type":"integer","minimum":0,"maximum":9007199254740991},"freeShippingThresholdInCents":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"allowLocalPickup":{"default":false,"type":"boolean"},"shippingNotes":{"type":"string","maxLength":500}},"required":["title"]}}}},"responses":{"200":{"description":"The new listing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OwnListing"}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/me/listings/{id}":{"get":{"operationId":"getOwnListing","summary":"Get one of your listings","tags":["Your listings"],"security":[{"ApiKey":["read"]}],"parameters":[{"in":"path","name":"id","schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OwnListing"}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}},"patch":{"operationId":"updateListing","summary":"Update a listing","description":"Changes only the fields you send.","tags":["Your listings"],"security":[{"ApiKey":["write"]}],"parameters":[{"in":"path","name":"id","schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"required":true}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":200},"description":{"description":"Plain text. Each line becomes a paragraph.","type":"string","maxLength":20000},"priceInCents":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"costInCents":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"quantity":{"default":1,"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"sku":{"type":"string","maxLength":100},"number":{"type":"string","maxLength":100},"categoryId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"gradingService":{"type":"string","maxLength":50},"grade":{"type":"string","maxLength":50},"certificateNumber":{"type":"string","maxLength":50},"attributes":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"null"}]}},"shippingMethod":{"default":"flat_rate","type":"string","enum":["flat_rate","free","calculated","pickup_only"]},"shippingCostInCents":{"type":"integer","minimum":0,"maximum":9007199254740991},"freeShippingThresholdInCents":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"allowLocalPickup":{"default":false,"type":"boolean"},"shippingNotes":{"type":"string","maxLength":500}}}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OwnListing"}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}},"delete":{"operationId":"deleteListing","summary":"Delete a listing","tags":["Your listings"],"security":[{"ApiKey":["write"]}],"parameters":[{"in":"path","name":"id","schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"deleted":{"type":"boolean","const":true}},"required":["id","deleted"],"additionalProperties":false}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/me/offers":{"get":{"operationId":"listOffers","summary":"List your offers","description":"Offers your organization sent or received, newest first.","tags":["Offers"],"security":[{"ApiKey":["read"]}],"parameters":[{"in":"query","name":"direction","schema":{"type":"string","enum":["sent","received"]}},{"in":"query","name":"status","schema":{"type":"string","enum":["pending","accepted","rejected","countered","expired","withdrawn"]}},{"in":"query","name":"open","schema":{"type":"string","enum":["true","false"]}},{"in":"query","name":"listingId","schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"}},{"in":"query","name":"page","schema":{"description":"Page number, starting at 1.","default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"in":"query","name":"limit","schema":{"description":"Results per page, 1 to 100.","default":20,"type":"integer","minimum":1,"maximum":100}}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Offer"}},"page":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"limit":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"hasMore":{"description":"True when another page follows this one.","type":"boolean"}},"required":["items","page","limit","hasMore"],"additionalProperties":false}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}},"post":{"operationId":"createOffer","summary":"Make an offer","description":"Offers a price for one unit of another dealer's listing. You can have one open offer per listing. Your organization must be a verified dealer.","tags":["Offers"],"security":[{"ApiKey":["write"]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"listingId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"amountInCents":{"description":"Your price for one unit.","type":"integer","minimum":1,"maximum":9007199254740991},"quantity":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991},"message":{"type":"string","maxLength":2000},"expiresInHours":{"description":"Hours the other side has to answer. Defaults to 48.","type":"integer","minimum":1,"maximum":336}},"required":["listingId","amountInCents"]}}}},"responses":{"200":{"description":"The new offer.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Offer"}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/me/offers/{id}":{"get":{"operationId":"getOffer","summary":"Get an offer","tags":["Offers"],"security":[{"ApiKey":["read"]}],"parameters":[{"in":"path","name":"id","schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Offer"}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/me/offers/{id}/counter":{"post":{"operationId":"counterOffer","summary":"Counter an offer","description":"Names a new price when the offer waits for you. A seller counters a pending offer. A buyer counters a countered offer.","tags":["Offers"],"security":[{"ApiKey":["write"]}],"parameters":[{"in":"path","name":"id","schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"required":true}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"amountInCents":{"description":"Your new price for one unit.","type":"integer","minimum":1,"maximum":9007199254740991},"message":{"type":"string","maxLength":2000},"expiresInHours":{"description":"Hours the other side has to answer. Defaults to 48.","type":"integer","minimum":1,"maximum":336}},"required":["amountInCents"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Offer"}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/me/offers/{id}/accept":{"post":{"operationId":"acceptOffer","summary":"Accept an offer","description":"Accepts the price on the table when the offer waits for you. This makes an order that holds the stock for 48 hours while the buyer pays. Open offers the remaining stock cannot fill are declined.","tags":["Offers"],"security":[{"ApiKey":["write"]}],"parameters":[{"in":"path","name":"id","schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Offer"}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/me/offers/{id}/decline":{"post":{"operationId":"declineOffer","summary":"Decline an offer","description":"Declines the offer when it waits for you. A buyer that wants to stop at any time can withdraw.","tags":["Offers"],"security":[{"ApiKey":["write"]}],"parameters":[{"in":"path","name":"id","schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"required":true}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","maxLength":2000}}}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Offer"}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/me/offers/{id}/withdraw":{"post":{"operationId":"withdrawOffer","summary":"Withdraw your offer","description":"Takes back an open offer you sent.","tags":["Offers"],"security":[{"ApiKey":["write"]}],"parameters":[{"in":"path","name":"id","schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Offer"}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/me/orders":{"get":{"operationId":"listOrders","summary":"List your orders","description":"Orders your organization bought (role=buyer) or sold (role=seller), newest first.","tags":["Orders"],"security":[{"ApiKey":["read"]}],"parameters":[{"in":"query","name":"role","schema":{"description":"Orders you bought, or orders you sold.","type":"string","enum":["buyer","seller"]},"required":true,"description":"Orders you bought, or orders you sold."},{"in":"query","name":"status","schema":{"type":"string","enum":["pending","confirmed","shipped","delivered","cancelled"]}},{"in":"query","name":"page","schema":{"description":"Page number, starting at 1.","default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"in":"query","name":"limit","schema":{"description":"Results per page, 1 to 100.","default":20,"type":"integer","minimum":1,"maximum":100}}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Order"}},"page":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"limit":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"hasMore":{"description":"True when another page follows this one.","type":"boolean"}},"required":["items","page","limit","hasMore"],"additionalProperties":false}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/me/orders/{id}":{"get":{"operationId":"getOrder","summary":"Get an order","tags":["Orders"],"security":[{"ApiKey":["read"]}],"parameters":[{"in":"path","name":"id","schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Order"}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}}},"components":{"schemas":{"Organization":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"name":{"type":"string"},"slug":{"type":"string"}},"required":["id","name","slug"],"additionalProperties":false},"error.BAD_REQUEST":{"title":"Invalid input data error (400)","description":"The error information","example":{"code":"BAD_REQUEST","message":"Invalid input data","issues":[]},"type":"object","properties":{"message":{"description":"The error message","example":"Invalid input data","type":"string"},"code":{"description":"The error code","example":"BAD_REQUEST","type":"string"},"issues":{"description":"An array of issues that were responsible for the error","example":[],"type":"array","items":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}},"required":["message","code"],"additionalProperties":false},"error.UNAUTHORIZED":{"title":"Authorization not provided error (401)","description":"The error information","example":{"code":"UNAUTHORIZED","message":"Authorization not provided","issues":[]},"type":"object","properties":{"message":{"description":"The error message","example":"Authorization not provided","type":"string"},"code":{"description":"The error code","example":"UNAUTHORIZED","type":"string"},"issues":{"description":"An array of issues that were responsible for the error","example":[],"type":"array","items":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}},"required":["message","code"],"additionalProperties":false},"error.FORBIDDEN":{"title":"Insufficient access error (403)","description":"The error information","example":{"code":"FORBIDDEN","message":"Insufficient access","issues":[]},"type":"object","properties":{"message":{"description":"The error message","example":"Insufficient access","type":"string"},"code":{"description":"The error code","example":"FORBIDDEN","type":"string"},"issues":{"description":"An array of issues that were responsible for the error","example":[],"type":"array","items":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}},"required":["message","code"],"additionalProperties":false},"error.NOT_FOUND":{"title":"Not found error (404)","description":"The error information","example":{"code":"NOT_FOUND","message":"Not found","issues":[]},"type":"object","properties":{"message":{"description":"The error message","example":"Not found","type":"string"},"code":{"description":"The error code","example":"NOT_FOUND","type":"string"},"issues":{"description":"An array of issues that were responsible for the error","example":[],"type":"array","items":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}},"required":["message","code"],"additionalProperties":false},"error.INTERNAL_SERVER_ERROR":{"title":"Internal server error error (500)","description":"The error information","example":{"code":"INTERNAL_SERVER_ERROR","message":"Internal server error","issues":[]},"type":"object","properties":{"message":{"description":"The error message","example":"Internal server error","type":"string"},"code":{"description":"The error code","example":"INTERNAL_SERVER_ERROR","type":"string"},"issues":{"description":"An array of issues that were responsible for the error","example":[],"type":"array","items":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}},"required":["message","code"],"additionalProperties":false},"Listing":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"slug":{"type":"string"},"title":{"type":"string"},"description":{"description":"Plain text.","anyOf":[{"type":"string"},{"type":"null"}]},"priceInCents":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991},{"type":"null"}]},"quantity":{"description":"Units available.","type":"integer","minimum":0,"maximum":9007199254740991},"gradingService":{"example":"PCGS","anyOf":[{"type":"string"},{"type":"null"}]},"grade":{"example":"MS65","anyOf":[{"type":"string"},{"type":"null"}]},"certificateNumber":{"anyOf":[{"type":"string"},{"type":"null"}]},"attributes":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"null"}]}},"category":{"anyOf":[{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"name":{"type":"string"},"slug":{"type":"string"}},"required":["id","name","slug"],"additionalProperties":false},{"type":"null"}]},"seller":{"anyOf":[{"$ref":"#/components/schemas/Organization"},{"type":"null"}]},"images":{"type":"array","items":{"type":"object","properties":{"url":{"type":"string"},"width":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]},"height":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]}},"required":["url","width","height"],"additionalProperties":false}},"shipping":{"type":"object","properties":{"method":{"type":"string","enum":["flat_rate","free","calculated","pickup_only"]},"costInCents":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991},{"type":"null"}]},"freeShippingThresholdInCents":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991},{"type":"null"}]},"allowLocalPickup":{"type":"boolean"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["method","costInCents","freeShippingThresholdInCents","allowLocalPickup","notes"],"additionalProperties":false},"url":{"description":"The listing on flowdealers.com.","type":"string"},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"},"updatedAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"},{"type":"null"}]}},"required":["id","slug","title","description","priceInCents","quantity","gradingService","grade","certificateNumber","attributes","category","seller","images","shipping","url","createdAt","updatedAt"],"additionalProperties":false},"OwnListing":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"slug":{"type":"string"},"title":{"type":"string"},"description":{"description":"Plain text.","anyOf":[{"type":"string"},{"type":"null"}]},"priceInCents":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991},{"type":"null"}]},"quantity":{"description":"Units available.","type":"integer","minimum":0,"maximum":9007199254740991},"gradingService":{"example":"PCGS","anyOf":[{"type":"string"},{"type":"null"}]},"grade":{"example":"MS65","anyOf":[{"type":"string"},{"type":"null"}]},"certificateNumber":{"anyOf":[{"type":"string"},{"type":"null"}]},"attributes":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"null"}]}},"category":{"anyOf":[{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"name":{"type":"string"},"slug":{"type":"string"}},"required":["id","name","slug"],"additionalProperties":false},{"type":"null"}]},"seller":{"anyOf":[{"$ref":"#/components/schemas/Organization"},{"type":"null"}]},"images":{"type":"array","items":{"type":"object","properties":{"url":{"type":"string"},"width":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]},"height":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]}},"required":["url","width","height"],"additionalProperties":false}},"shipping":{"type":"object","properties":{"method":{"type":"string","enum":["flat_rate","free","calculated","pickup_only"]},"costInCents":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991},{"type":"null"}]},"freeShippingThresholdInCents":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991},{"type":"null"}]},"allowLocalPickup":{"type":"boolean"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["method","costInCents","freeShippingThresholdInCents","allowLocalPickup","notes"],"additionalProperties":false},"url":{"description":"The listing on flowdealers.com.","type":"string"},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"},"updatedAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"},{"type":"null"}]},"sku":{"anyOf":[{"type":"string"},{"type":"null"}]},"number":{"description":"Your own lot or stock number.","anyOf":[{"type":"string"},{"type":"null"}]},"costInCents":{"description":"What you paid. Never shown to buyers.","anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991},{"type":"null"}]},"status":{"type":"string","enum":["active","sold","delisted"]},"soldAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"},{"type":"null"}]},"delistedAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"},{"type":"null"}]}},"required":["id","slug","title","description","priceInCents","quantity","gradingService","grade","certificateNumber","attributes","category","seller","images","shipping","url","createdAt","updatedAt","sku","number","costInCents","status","soldAt","delistedAt"],"additionalProperties":false},"Offer":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"listing":{"anyOf":[{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"title":{"type":"string"}},"required":["id","title"],"additionalProperties":false},{"type":"null"}]},"direction":{"description":"Whether your organization sent or received it.","type":"string","enum":["sent","received"]},"buyer":{"anyOf":[{"$ref":"#/components/schemas/Organization"},{"type":"null"}]},"seller":{"anyOf":[{"$ref":"#/components/schemas/Organization"},{"type":"null"}]},"amountInCents":{"description":"The buyer's latest price for one unit.","type":"integer","minimum":0,"maximum":9007199254740991},"quantity":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"message":{"anyOf":[{"type":"string"},{"type":"null"}]},"status":{"description":"pending waits for the seller. countered waits for the buyer. accepted has an order that waits for payment or is paid.","type":"string","enum":["pending","accepted","rejected","countered","expired","withdrawn"]},"closeReason":{"anyOf":[{"description":"Why Flow Dealers closed the offer. Null when the buyer or seller closed it.","type":"string","enum":["listing_sold","not_enough_stock","listing_unavailable","payment_missed"]},{"type":"null"}]},"yourTurn":{"description":"True when the offer waits for your organization to answer.","type":"boolean"},"counterAmountInCents":{"description":"The seller's latest counter price for one unit.","anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991},{"type":"null"}]},"counterMessage":{"anyOf":[{"type":"string"},{"type":"null"}]},"respondedAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"},{"type":"null"}]},"expiresAt":{"description":"While open, the time to answer by. When accepted, the time the buyer must pay by.","anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"},{"type":"null"}]},"orderId":{"description":"The order an accepted offer made. Pay it in the Flow Dealers app.","anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},{"type":"null"}]},"history":{"description":"Every step of the offer, oldest first.","type":"array","items":{"type":"object","properties":{"action":{"type":"string","enum":["placed","countered","accepted","declined","withdrawn","expired"]},"by":{"description":"Who took the step. platform means an expiry or a close after a sale.","type":"string","enum":["buyer","seller","platform"]},"amountInCents":{"description":"The price for one unit that this step named.","anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991},{"type":"null"}]},"message":{"anyOf":[{"type":"string"},{"type":"null"}]},"closeReason":{"anyOf":[{"description":"Why Flow Dealers closed the offer. Null when the buyer or seller closed it.","type":"string","enum":["listing_sold","not_enough_stock","listing_unavailable","payment_missed"]},{"type":"null"}]},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"}},"required":["action","by","amountInCents","message","closeReason","createdAt"],"additionalProperties":false}},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"}},"required":["id","listing","direction","buyer","seller","amountInCents","quantity","message","status","closeReason","yourTurn","counterAmountInCents","counterMessage","respondedAt","expiresAt","orderId","history","createdAt"],"additionalProperties":false},"Order":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"listing":{"anyOf":[{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"title":{"type":"string"}},"required":["id","title"],"additionalProperties":false},{"type":"null"}]},"role":{"description":"Your organization's side of the order.","type":"string","enum":["buyer","seller"]},"buyer":{"anyOf":[{"$ref":"#/components/schemas/Organization"},{"type":"null"}]},"seller":{"anyOf":[{"$ref":"#/components/schemas/Organization"},{"type":"null"}]},"quantity":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"itemPriceInCents":{"type":"integer","minimum":0,"maximum":9007199254740991},"shippingCostInCents":{"type":"integer","minimum":0,"maximum":9007199254740991},"platformFeeInCents":{"description":"The buyer's platform fee.","type":"integer","minimum":0,"maximum":9007199254740991},"paymentProcessingFeeInCents":{"type":"integer","minimum":0,"maximum":9007199254740991},"sellerPlatformFeeInCents":{"description":"Only returned to the seller.","anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991},{"type":"null"}]},"totalAmountInCents":{"type":"integer","minimum":0,"maximum":9007199254740991},"status":{"example":"confirmed","type":"string"},"paymentStatus":{"example":"succeeded","type":"string"},"paymentMethod":{"anyOf":[{"type":"string"},{"type":"null"}]},"shipment":{"type":"object","properties":{"carrier":{"anyOf":[{"type":"string"},{"type":"null"}]},"trackingNumber":{"anyOf":[{"type":"string"},{"type":"null"}]},"trackingUrl":{"anyOf":[{"type":"string"},{"type":"null"}]},"shippedAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"},{"type":"null"}]},"deliveredAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"},{"type":"null"}]}},"required":["carrier","trackingNumber","trackingUrl","shippedAt","deliveredAt"],"additionalProperties":false},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"},"updatedAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-]\\d{2}:\\d{2})))$"},{"type":"null"}]}},"required":["id","listing","role","buyer","seller","quantity","itemPriceInCents","shippingCostInCents","platformFeeInCents","paymentProcessingFeeInCents","sellerPlatformFeeInCents","totalAmountInCents","status","paymentStatus","paymentMethod","shipment","createdAt","updatedAt"],"additionalProperties":false}},"securitySchemes":{"ApiKey":{"type":"http","scheme":"bearer","description":"An API key. Keys start with fd_live_. Each key has scopes: read (GET requests) and, unless the key is read-only, write (requests that change data). Scopes are also listed in the protected resource metadata (RFC 9728)."}}}}