Financial Endpoints
GET All Allocations
Get all allocations in Aprimo DM.
Endpoint | /api/v1.0/funding/allocations |
---|---|
Method | GET |
Request Body Sample | N/A. |
Response Body Sample
{
"Allocations": [
{
"AllocationId": 4729,
"Name": "FY2015 Q1",
"Comments": "This is the allocation for 2015, quarter 1.",
"ExpirationDate": "2015-06-30",
"Funds": [
{
"PartnerID": 1830,
"Amount": "7493.00"
},
{
"PartnerID": 3830,
"Amount": "7493.10"
}
],
"ErrorCode": 0,
"ErrorMessage": null
},
{
"AllocationId": 1253,
"Name": "FY2015 Q2",
"Comments": "This is the allocation for 2015, quarter 1.",
"ExpirationDate": "2015-03-30",
"Funds": [
{
"PartnerID": 1831,
"Amount": "7493.00"
},
{
"PartnerID": 3832,
"Amount": "7493.10"
}
],
"ErrorCode": 0,
"ErrorMessage": null
}
],
"ErrorCode": 0,
"ErrorMessage": null
}
GET Allocation
Get a single allocation back in Aprimo DM.
Endpoint | /api/v1.0/funding/allocations/{id} |
---|---|
Method | GET |
Request Body Sample | N/A. |
Response Body Sample
{
"Allocations": [
{
"AllocationId": 4729,
"Name": "FY2015 Q1",
"Comments": "This is the allocation for 2015, quarter 1.",
"ExpirationDate": "2015-06-30",
"Funds": [
{
"PartnerID": 1830,
"Amount": "7493.00"
},
{
"PartnerID": 3830,
"Amount": "7493.10"
}
],
"ErrorCode": 0,
"ErrorMessage": null
}
],
"ErrorCode": 0,
"ErrorMessage": null
}
POST Create New Allocation
Create a new funding allocation and specify the partners and dollars to be issued. This supports expiration date restrictions.
Endpoint | /api/v1.0/funding/allocations |
---|---|
Method | POST |
Request Headers | Content-Type : application/json |
Request Body Sample
{
"Name": "FY2015 Q1",
"Comments": "This is the allocation for 2015, quarter 1.",
"ExpirationDate": "2015-03-30",
"Funds": [
{
"PartnerID": "1830",
"Amount": "7493.00"
},
{
"PartnerID": "3830",
"Amount": "3802.65"
}
]
}
Response Body Sample
{
"AllocationId": 4729,
"Name": "FY2015 Q1",
"Comments": "This is the allocation for 2015, quarter 1.",
"ExpirationDate": "2015-03-30",
"Funds": [
{
"PartnerID": 1830,
"Amount": "7493.00"
},
{
"PartnerID": 3830,
"Amount": "7493.10"
}
],
"ErrorCode": 0,
"ErrorMessage": null
}
PATCH Update Existing Allocation
Update an existing allocation. You may only add new partners to an existing allocation.
Endpoint | /api/v1.0/funding/allocations/{id} |
---|---|
Method | PATCH |
Request Headers | Content-Type : application/json |
Request Body Sample
{
"AllocationId": "4729",
"Funds": [
{
"PartnerID": "3244",
"Amount": "43.00"
},
{
"PartnerID": "7653",
"Amount": "23.65"
}
]
}
Response Body Sample
{
"AllocationId": 5654,
"Name": "FY2015 Q1",
"Comments": "This is the allocation for 2015, quarter 1.",
"ExpirationDate": "2015-03-30",
"Funds": [
{
"PartnerID": 1830,
"Amount": "7493.00"
},
{
"PartnerID": 3830,
"Amount": "3802.00"
},
{
"PartnerID": 3244,
"Amount": "43.00"
},
{
"PartnerID": 7653,
"Amount": "23.65"
}
],
"ErrorCode": 0,
"ErrorMessage": ""
}
GET Wallet Balance
Get the wallet balance of a partner in order to see how many dollars they have available.
Endpoint | /api/v1.0/funding/partnerwallet/{id} |
---|---|
Method | GET |
Request Headers | Content-Type : application/json |
Request Body Sample | N/A |
Response Body Sample
{
"PartnerId": 3242,
"PartnerName": "ACME",
"TotalFundsAvailable": "11362.30",
"Funds": [
{
"AllocationId": 3142,
"Amount": "7493.00"
},
{
"AllocationId": 342,
"Amount": "3802.65"
},
{
"AllocationId": 5425,
"Amount": "43.00"
},
{
"AllocationId": 657,
"Amount": "23.65"
}
],
"ErrorCode": 0,
"ErrorMessage": null
}