Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Holds, reservations and authorizations are all pretty much the same thing. This is what happens to your credit card when you rent a car
for example. The merchant authorizes a certain amount on your card, which is now guaranteed within a certain amount of time. When it comes time to charge the account the merchant provides the actual amount which now gets released into merchants account and the authorization is released. It could also be used in exchanges where a third party agent has a hold on some value from your account in order to match bids.
There doesn’t need to be anything specifically about this in the standard as it can be implemented as just another use case.
So in OpenTransact any unit of value has an opentransact url. Eg.
Now a hold essentially produces a different type of value that is separate from the “parent” asset.
http://hellobank.com/euro/held is an asset of value that is held temporarily.
So to create a held value I post to:POST /euro/held which creates the hold /euro/held/abcdefg12345
This if taken to its conclusion is not just a transaction, but it creates a completely different type of asset a short lived special purpose asset consisting of the held funds.
This can now be used for a single or multiple payments to charge the hold. Just like with PayPal X and Amazon Adaptive Payments.
I charge it by just treating the above transaction url as any other opentransact url:POST /euro/held/abcdefg12345
Which creates an actual transaction under /euro
The only thing outside the OpenTransact standard itself is that you should be able to explicitly expire a transaction using the DELETE
This is of course optional to the implementer.
But in this case holds can be implemented as just another use case ontop of OpenTransact without adding anything to the standard.