ContactsApi
All URIs are relative to https://freshdesk.com/api/v2
Method | HTTP request | Description |
---|---|---|
cancelContactImport | PUT /contacts/imports/{id}/cancel | Cancel contact import |
createContact | POST /contacts | Add a Contact |
deleteContact | DELETE /contacts/{id} | Delete a Contact |
exportContacts | POST /contacts/export | Export contacts |
getAllContacts | GET /contacts | Get all Contacts |
getContact | GET /contacts/{id} | Get a contact |
getContactFields | GET /contact_fields | Get Contact Fields |
getContactImportDetails | GET /contacts/imports/{id} | Get contact import's details |
getExportedContact | GET /contacts/export/{id} | Get exported contact |
getImportedContacts | GET /contacts/imports | Get imported contacts details |
hardDeleteContact | DELETE /contacts/{id}/hard_delete | Hard delete a Contact |
importContact | POST /contacts/imports | Import contact |
inviteContact | PUT /contacts/{id}/send_invite | Send Invite to a Contact |
makeAgent | PUT /contacts/{id}/make_agent | Convert Contact to an Agent |
mergeContacts | POST /contacts/merge | Merge two contacts |
restoreContact | PUT /contacts/{id}/restore | Restore a Contact |
searchContacts | GET /search/contacts | search Contacts |
updateContact | PUT /contacts/{id} | Update a contact |
cancelContactImport
Cancel contact import
Method syntax: ContactImportDetails cancelContactImport(id)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
id | String |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
createContact
Add a Contact
Method syntax: Contact createContact(contact)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
contact | Contact |
Return type
Authorization
HTTP request headers
- Content-Type: application/json, multipart/form-data
- Accept: application/json
deleteContact
Delete a Contact
Method syntax: deleteContact(id)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
id | Number |
Return type
null (empty response body)
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
exportContacts
Export contacts
Method syntax: InlineResponse200 exportContacts(contactMergeInput)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
contactMergeInput | ContactsExport |
Return type
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json
getAllContacts
Get all Contacts
Method syntax: [Contact] getAllContacts(opts)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
String | [optional] | ||
mobile | String | [optional] | |
phone | String | [optional] | |
companyId | String | [optional] | |
state | String | [optional] | |
updatedSince | String | [optional] | |
perPage | Number | [optional] |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
getContact
Get a contact
Method syntax: Contact getContact(id)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
id | Number |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
getContactFields
Get Contact Fields
Method syntax: [ContactField] getContactFields()
Parameters
This endpoint does not need any parameter.
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
getContactImportDetails
Get contact import's details
Method syntax: ContactImportDetails getContactImportDetails(id)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
id | String |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
getExportedContact
Get exported contact
Method syntax: ExportedContact getExportedContact(id)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
id | String |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
getImportedContacts
Get imported contacts details
Method syntax: [ContactImportDetails] getImportedContacts(opts)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
status | String | [optional] |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
hardDeleteContact
Hard delete a Contact
Method syntax: hardDeleteContact(id)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
id | Number |
Return type
null (empty response body)
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
importContact
Import contact
Method syntax: ContactImportDetails importContact(file, fieldsName, fieldsEmail, fieldsCompanyName)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
file | File | ||
fieldsName | String | ||
fieldsEmail | String | ||
fieldsCompanyName | String |
Return type
Authorization
HTTP request headers
- Content-Type: multipart/form-data
- Accept: application/json
inviteContact
Send Invite to a Contact
Method syntax: inviteContact(id)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
id | Number |
Return type
null (empty response body)
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
makeAgent
Convert Contact to an Agent
Method syntax: MakeAgentResponse makeAgent(id, opts)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
id | Number | ||
makeAgent | MakeAgentRequest | [optional] |
Return type
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json
mergeContacts
Merge two contacts
Method syntax: mergeContacts(contactMergeInput)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
contactMergeInput | ContactMergeInput |
Return type
null (empty response body)
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json
restoreContact
Restore a Contact
Method syntax: restoreContact(id)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
id | Number |
Return type
null (empty response body)
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
searchContacts
search Contacts
Method syntax: ContactSearch searchContacts(opts)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
query | String | [optional] |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
updateContact
Update a contact
Method syntax: Contact updateContact(id, contact)
Parameters
Name | Type | Description | Notes |
---|---|---|---|
id | Number | ||
contact | Contact |
Return type
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json