Hello,
We are getting a “500 Internal Server Error” when attempting to create a Gift with a Custom Field with type CodeTableEntry for an existing Constituent. Note: we are able to create a Gifts with Custom Fields of all other types (Text, Boolean, etc) as expected.
We're wondering if the issue is on BB's side or if our syntax for CodeTableEntry Custom Fields might be incorrect.
In the example below, our Custom Field: “Are you a member?” is a CodeTableEntry with the following values:
Request URL
https://api.sky.blackbaud.com/gift/v1/gifts/customfields/categories/values?category_name=Are you a member?
Response
{
"count": 3,
"value": ["No thanks", "Not yet; I'd like to become a member", "Yes, I'm already a member."]
}
In the create Gift API request below, we pass “No thanks” as the Custom Field value. Which results in a 500 Internal Server Error.
Request
POST https://api.sky.blackbaud.com/gift/v1/gifts HTTP/1.1
Host: api.sky.blackbaud.com
Content-Type: application/json
Bb-Api-Subscription-Key: ••••
Authorization: ••••
{
"amount": {
"value": 5
},
"gift_splits": [
{
"amount": {
"value": 5
},
"fund_id": "21"
}
],
"type": "Donation",
"payments": [
{
"payment_method": "CreditCard"
}
],
"custom_fields": [
{
"category": "Are you a member?",
"value": "No thanks"
}
],
"constituent_id": "330387"
}
Note 2: When we use RE NXT Web View, extract the option value from the Add Gift form, and pass that as the “Are you a member?” Custom Field value, we are able to successfully Add the Gift via the API, but we do not see a way of obtaining this value via API. Repeating the above Add Gift request with the custom fields edited below example works as expected:
"custom_fields": [
{
"category": "Are you a member?",
"value": "73466"
}
]

Thank you,
Aaron