Quick Start Guide
This is a very short description of what is needed to get started with the Magic Receipts API
Credentials
my app token
<YOUR_TOKEN_HERE>
get 2 hour's access token
\-X GET <https://api.bitlabs.ai/v1/client/magic-receipts/access-token>
-H "X-Api-Token: \<YOUR_TOKEN_HERE>"
-H "X-User-Id: 124"
This is your header with the token that authenticates your user
\-H "Authorization: Bearer ODAxOTAzN34xNzE5NDQ5NzQ5fmI5ODUyMTc5ODhlMjU1ZDhjMjE1M2E4MmIxNmE2ZDczNWM0YjdmMWFmOWVjOGJhYzM0NmZiYjYyYjRhZDQ0OTI="
Check specific offer
curl '<https://receipts.bitlabs.ai/?cmd=mp-mr-api-offer-details&offerID=7174682&_bg=false'>
-H "Authorization: Bearer ODAxOTAzN34xNzE5NDQ5NzQ5fmI5ODUyMTc5ODhlMjU1ZDhjMjE1M2E4MmIxNmE2ZDczNWM0YjdmMWFmOWVjOGJhYzM0NmZiYjYyYjRhZDQ0OTI="
Check for all offers
curl '<https://receipts.bitlabs.ai/?cmd=mp-mr-api-offers-short'>
-H "Authorization: Bearer ODAxOTAzN34xNzE5NDQ5NzQ5fmI5ODUyMTc5ODhlMjU1ZDhjMjE1M2E4MmIxNmE2ZDczNWM0YjdmMWFmOWVjOGJhYzM0NmZiYjYyYjRhZDQ0OTI="
Clip offer
curl '<https://receipts.bitlabs.ai/?cmd=mp-mr-api-offer-action'>
-H "Authorization: Bearer ODAxOTAzN34xNzE5NDQ5NzQ5fmI5ODUyMTc5ODhlMjU1ZDhjMjE1M2E4MmIxNmE2ZDczNWM0YjdmMWFmOWVjOGJhYzM0NmZiYjYyYjRhZDQ0OTI="
--data-raw 'offerID=7215012&action=add'
Check clipped offers
curl '<https://receipts.bitlabs.ai/?cmd=mp-mr-api-offers-short&sortType=0&myList=true'>
-H "Authorization: Bearer ODAxOTAzN34xNzE5NDQ5NzQ5fmI5ODUyMTc5ODhlMjU1ZDhjMjE1M2E4MmIxNmE2ZDczNWM0YjdmMWFmOWVjOGJhYzM0NmZiYjYyYjRhZDQ0OTI="
Upload a receipt
curl -X POST '<https://receipts.bitlabs.ai/?cmd=mp-mr-api-upload-receipt&imageCount=1&offerIDs=7215012&merchantID=11'>
-H "Authorization: Bearer ODAxOTAzN34xNzE5NDQ5NzQ5fmI5ODUyMTc5ODhlMjU1ZDhjMjE1M2E4MmIxNmE2ZDczNWM0YjdmMWFmOWVjOGJhYzM0NmZiYjYyYjRhZDQ0OTI="
-F 'img0=@/Users/eric.h/Desktop/testimage2.png;type=image/png'
-F 'imgName0=testimage2.png'
Request manual review
curl '<https://receipts.bitlabs.ai/?cmd=mp-mr-api-manual-review&uploadOfferIDs=170563011'>
-X 'POST'
-H "Authorization: Bearer ODAxOTAzN34xNzE5NDQ5NzQ5fmI5ODUyMTc5ODhlMjU1ZDhjMjE1M2E4MmIxNmE2ZDczNWM0YjdmMWFmOWVjOGJhYzM0NmZiYjYyYjRhZDQ0OTI="
Updated 2 months ago