List codes
The codes your organization uses for gifts, thank-you letters and contacts.
GET https://cotlet.dev/api/v1/donorperfect/codes
read
Returns the code and its description for one code list from Settings > Code Maintenance. field picks the list. The codes belong to your organization, so the answer differs from one DonorPerfect account to the next. add_gift, create_pledge and add_contact take the code, not the description.
Parameters
| Name | Type | Description |
|---|---|---|
| field enum required | enum | solicitation, general_ledger, gift_type, thank_you_letter, activity_code or by_whom. |
Request
curl "https://cotlet.dev/api/v1/donorperfect/codes?field=solicitation" \
-H "Authorization: Bearer $COTLET_API_KEY" result = client.call("donorperfect", "list_codes", {"field":"solicitation"}) const result = await cotlet.call('donorperfect', 'list_codes', {"field":"solicitation"}); cotlet call donorperfect list_codes --data '{"field":"solicitation"}' Example response
{
"field": "thank_you_letter",
"codes": [
{
"code": "STANDARD",
"description": "Standard thank you"
},
{
"code": "MAJOR",
"description": "Major donor thank you"
}
]
}