Obtaining your API Key

To obtain your API key, log into KeyPay and click your name in the top right corner, then click My Account.

Click Generate API Key and a key will be generated for you.

Your key will now be generated. Double click the text and copy it. Store this key somewhere safe. Please note that clicking Change API Key will invalidate your old API key.

Authenticating HTTP Requests

Requests will be authenticated using HTTP Basic Authentication . The API Key will become the username of your request and the password can be left blank.

To confirm that your API key is working, you can use the curl command line application on UNIX style operating systems.

curl -u RURQT1UyMm5vSnViZnNxZGlhMmJuUT09:
https://{yourwhitelabel}.yourpayroll.com.au/api/v2/user

You should receive a response:

{
    "id": 14144,
    "email": "joe.bloggs@test.com",
    "displayName": "Joe Bloggs",
    "timeZone": "AUS Eastern Standard Time"
}