Version v2.2
The API is organized around HTTP and Protocol Buffers.
Our API is designed to have predictable, resource-oriented URLs and to use HTTP response codes to indicate API errors. We use built-in HTTP features, like HTTP authentication and HTTP verbs, which can be understood by off-the-shelf HTTP clients.
Requests and responses are serialized using Protocol Buffers, including errors -- think XML, but smaller, faster, and simpler.
There are lots of pre-built libraries for interacting with JPurse.
JPurse uses conventional HTTP response codes to indicate success or failure of a request.
200 OK | Everything worked as expected. |
400 Bad Request | Often missing a required parameter, or parameters were valid but request failed. For all bad requests, we return a FaultResponse. |
401 Unauthorized | No valid authentication credentials provided. |
404 Not Found | The requested item doesn’t exist. |
500, 502, 503, 504 Server errors | Something went wrong on JPurse’s end. |
Returns information about the backend such as version.
HTTP GET
ABOUT
Request entity: none
Response entity: AboutResponse
HTTP POST
permitAll
Request entity: AuthenticateDeviceRequest
Response entity: <AuthenticateDeviceResponse>
Show the current balance of a user. The quantity of each product and the amount of cash registered to a user is returned as response.
HTTP POST
BALANCE
Request entity: BalanceRequest
Response entity: BalanceResponse
Shows the transactions of the balance history for a user, device or program. Every transaction shows how the balance was updated.
HTTP POST
BALANCE
Request entity: BalanceHistoryRequest
Response entity: BalanceHistoryResponse
Lock a Card based on its card identifier.
HTTP POST
CONFIGURE_CARD
Request entity: LockCardRequest
Response entity: none
Unlock a Card based on its card identifier.
HTTP POST
CONFIGURE_CARD
Request entity: UnLockCardRequest
Response entity: none
HTTP POST
CHECK_CARD
Request entity: <CardInfoRequest>
Response entity: CardInfoResponse
HTTP POST
GENERATE_CARDS
Request entity: GenerateCardsBatchRequest
Response entity: GenerateCardsBatchResponse
HTTP POST
CONFIGURE_MERCHANT_USER
Request entity: AddUserRequest
Response entity: none
HTTP POST
CONFIGURE_COUPON
Request entity: AddCouponRequest
Response entity: <AssignCouponResponse>
HTTP POST
ASSIGN_COUPON
Request entity: AssignCouponRequest
Response entity: <AssignCouponResponse>
HTTP POST
LIST_COUPONS
Request entity: ListCouponRequest
Response entity: ListCouponResponse
HTTP POST
LIST_COUPON_ASSIGNMENTS
Request entity: RequestCouponAssignmentRequest
Response entity: <RequestCouponAssignmentResponse>
Create a customer.
HTTP POST
CONFIGURE_USER
Request entity: CreateCustomerRequest
Response entity: none
Register a customer.
HTTP POST
CONFIGURE_USER
Request entity: RegisterCustomerRequest
Response entity: RegisterCustomerResponse
Register a raffle user as a new customer.
HTTP POST
CONFIGURE_USER
Request entity: RegisterCustomerRequest
Response entity: RegisterCustomerResponse
Reset the password of a user’s identifier.
HTTP POST
CONFIGURE_USER
Request entity: ResetPasswordRequest
Response entity: none
Change the password of a user’s identifier.
HTTP POST
CONFIGURE_USER
Request entity: ChangePasswordRequest
Response entity: none
Lock a gift.
HTTP POST
CONFIGURE_GIFT
Request entity: LockGiftRequest
Response entity: none
Claim a gift.
HTTP POST
CLAIM_GIFT
Request entity: ClaimGiftRequest
Response entity: ClaimGiftResponse
Claim a list gift.
HTTP POST
CLAIM_GIFT
Request entity: ClaimGiftsRequest
Response entity: none
Issue a gift.
HTTP POST
ISSUE_GIFT
Request entity: IssueGiftRequest
Response entity: IssueGiftResponse
Issue a list of gifts.
HTTP POST
ISSUE_GIFT
Request entity: IssueGiftsRequest
Response entity: none
Balance of a gift.
HTTP POST
BALANCE
Request entity: BalanceGiftRequest
Response entity: BalanceGiftResponse
Reversal of a gift action.
HTTP POST
BALANCE
Request entity: ReversalRequest
Response entity: none
Creation of a gift
HTTP POST
CONFIGURE_GIFT
Request entity: CreateGiftRequest
Response entity: CreateGiftResponse
Update gift pincode
HTTP POST
CONFIGURE_GIFT
Request entity: UpdateGiftPincodeRequest
Response entity: none
Link a gift to a user
HTTP POST
CONFIGURE_GIFT
Request entity: LinkGiftToUserRequest
Response entity: none
HTTP POST
CONFIGURE_GIFT
Request entity: <CreateGiftsRequest>
Response entity: CreateGiftsResponse
Retrieve information on a gift
HTTP POST
BALANCE
Request entity: GiftInfoRequest
Response entity: GiftInfoResponse
HTTP POST
REWARD
Request entity: RewardListRedeemRulesRequest
Response entity: RewardListRedeemRulesResponse
HTTP POST
LOYALTY_START
Request entity: StartLoyaltyRequest
Response entity: StartLoyaltyResponse
HTTP POST
CONFIGURE_PRODUCT
Request entity: AddProductsToProgramsRequest
Response entity: none
Raffle Question Retrieval
HTTP POST
RAFFLE_VALIDATION
Request entity: RaffleQuestionRetrievalRequest
Response entity: RaffleQuestionRetrievalResponse
Raffle Ticket Validation
HTTP POST
RAFFLE_VALIDATION
Request entity: RaffleTicketValidationRequest
Response entity: RaffleTicketValidationResponse
Raffle Price Validation
HTTP POST
RAFFLE_PRICE
Request entity: RafflePriceValidationRequest
Response entity: RafflePriceValidationResponse
Raffle Price Claiming
HTTP POST
RAFFLE_PRICE
Request entity: RaffleTicketValidationClaimRequest
Response entity: none
Redeem.
HTTP POST
REDEEM
Request entity: RedeemRequest
Response entity: RedeemResponse
List the redeem rules.
HTTP POST
LIST_RULES
Request entity: ListRedeemRuleRequest
Response entity: ListRedeemRuleResponse
List the redeem rules of a merchant.
HTTP POST
LIST_RULES_FOR_MERCHANT
Request entity: ListRuleForMerchantRequest
Response entity: ListRedeemRuleResponse
HTTP POST
TOPUP
Request entity: ReversalRequest
Response entity: none
Reward.
HTTP POST
REWARD
Request entity: RewardRequest
Response entity: RewardResponse
List the reward rules of a merchant.
HTTP POST
LIST_RULES_FOR_MERCHANT
Request entity: ListRuleForMerchantRequest
Response entity: ListRewardRuleResponse
HTTP POST
LIST_RULES
Request entity: ListRuleForCardRequest
Response entity: ListRewardRuleResponse
HTTP POST
permitAll
Request entity: ListSlideRequest
Response entity: <ListSlideResponse>
HTTP POST
LIST_TRANSACTIONS
Request entity: StatisticRequest
Response entity: StatisticResponse
Top down.
HTTP POST
TOPDOWN
Request entity: TopDownRequest
Response entity: TopDownResponse
Top down product.
HTTP POST
TOPDOWN
Request entity: TopDownRequest
Response entity: TopDownProductResponse
HTTP POST
TOPUP
Request entity: TopUpByCashRequest
Response entity: TopUpResponse
HTTP POST
TOPUP
Request entity: TopUpByUserRequest
Response entity: none
Authenticate a user.
HTTP POST
AUTHENTICATE_USER
Request entity: AuthenticateUserRequest
Response entity: AuthenticateUserResponse
Lock a user.
HTTP POST
CONFIGURE_USER
Request entity: LockUserRequest
Response entity: none
Clean a user.
HTTP POST
CONFIGURE_USER
Request entity: CleanUserRequest
Response entity: none
Find a user.
HTTP POST
LIST_USERS
Request entity: FindUserRequest
Response entity: FindUserResponse
Find users.
HTTP POST
LIST_USERS
Request entity: FindUsersRequest
Response entity: FindUsersResponse
Add a card to a user.
HTTP POST
CONFIGURE_USER
Request entity: AddCardToUserRequest
Response entity: none
Removes a card from a user.
HTTP POST
CONFIGURE_USER
Request entity: RemoveCardFromUserRequest
Response entity: none
Removes the link between the User and the UserIdentifier for the given identifier. <br/> The identifier can be an email address or a card. Optionally the card can be locked.
HTTP POST
CONFIGURE_USER
Request entity: RemoveIdentifierFromUserRequest
Response entity: none
Moves all details from one user to another. <br/> Details that are moved are: - transactions - couponassignments - gifts - balances. <br/> Boolean MoveUserAndIdentifierData indicates to move all user data and email user identifiers.
HTTP POST
CONFIGURE_USER
Request entity: MoveUserRequest
Response entity: none
Subscribes the user by it’s userIdentifier identifier. <br/> The identifier can be an email address or a card.
HTTP POST
CONFIGURE_USER
Request entity: SubscribeUserRequest
Response entity: none
Unsubscribes the user by it’s userIdentifier identifier. <br/> The identifier can be an email address or a card.
HTTP POST
CONFIGURE_USER
Request entity: UnsubscribeUserRequest
Response entity: none
HTTP POST
permitAll
Request entity: ListVideoRequest
Response entity: <ListVideoResponse>