Skip to content
Pawel Sawicz edited this page Dec 5, 2015 · 1 revision

The following example charities and code examples should help you get any application up and running. Any questions, please contact @jghackers for support throughout the course of the hack.

Charities

To test on sandbox please use charityID = 2050 as they are not listed on this environment.

Get Charity Details API

Simple Donation Integration (SDI)

Check out developer portal that will help you to construct SDI

A donation can be pre-constructed via the SDI which will take the donor from your app to JustGiving to make their donation and then back to a URL or AppID of your choosing. This allows you to start and finish the donation journey. You can also then query the donationID for additional data.

You build and promote a custom link to our donation process with extra parameters on the query string:

  • charityID
  • amount
  • currency
  • reference (optional)
  • exitURL (optional)

Donor donates on JustGiving after following or being redirected to your link Donor is redirected based on the query string parameters you supply. As part of the redirection, the JustGiving Donation ID of the donation that was processed is supplied as a query string parameter, allowing you to request data related to the donation using the JustGiving API.

Example SDI link

http://www.justgiving.com/4w350m3/donation/direct/charity/{charityID}?amount=50&currency=GBP&exitUrl=http%3A%2F%2Fwww.facebook.com%3Fjg?donationId=JUSTGIVING-DONATION-ID

Querying a donation

Every donation successfully made will have a donationID returned (either via the SDI or in your email receipt) and sometimes the reference you attached to it via the SDI.

You can query that donation using the Donations resources

Test card details

You can make test donations on sandbox against any charity. Details on cards to use here