Just a quick note about using custom fields with the API.
1. All fields must be between a single set of <custom_field></customfield> tags
If you use <custom_field> tags for each field, you will get an error.
2. Custom field names are not what you think. The best way to discover them is by looking at the source of the ticket submission form. You can also use this to devine the possible values of dropdowns.
3. Many more fields are available. If you look at the return, it will give you an idea of what can be set - quite a lot of these are not in the docs...
HTH someone and you won't have to spend hours guessing how it works.
We now have an improvised , stable API version with elaborate error codes. You can find the documentation here : API V2
More information on the custom field usage in API can be found here: https://support.freshdesk.com/support/solutions/articles/216548