Skip to content

Instantly share code, notes, and snippets.

@AndrewHenderson
Last active November 5, 2015 02:08
Show Gist options
  • Save AndrewHenderson/5b0fbc148a98b6dc4bcb to your computer and use it in GitHub Desktop.
Save AndrewHenderson/5b0fbc148a98b6dc4bcb to your computer and use it in GitHub Desktop.
// GET /preapprovals/1?applyExpenseHeaderId=3 HTTP/1.1
{
"links": {
"self": "/preapprovals/1"
},
"data" : {
"type" : "preapprovals",
"id" : "1",
"attributes" : {
"name": "test 1",
"itemTypeTotals": [
{
"paExpenseTypeName": "Parking",
"remainingBalance" : "250",
"spentAmount" : "100"
},
{
"paExpenseTypeName": "Airfare",
"remainingBalance" : "1250",
"spentAmount" : "1100"
}
]
}
}
}
// POST /preapprovals/1/relationships/expensereports HTTP/1.1
{
"data": {
"type": "expensereports",
"id" : "3"
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment