Get started
Quickstart
Copy these curl calls against the sandbox. Expand a sample label below each call to see typical JSON. Replace placeholders after your account is approved — or log in to fill them automatically.
1 Send a fax
Fax_SendFax — multipart with Files0. Destination last 4 digits pick the final Call Result. Job stays Submitted for 2 minutes, then finalizes. ProductId is the fax line id from List fax lines.
Numbers1=5552001111 → Call Result Sent after the 2-minute window.
curl -s -X POST "https://integrate.westfax.com/rest/Fax_SendFax/json" \
-H "x-api-key: YOUR_X_API_KEY" \
-F "ProductId=YOUR_PRODUCT_ID" \
-F "JobName=Sandbox Sent" \
-F "Header=From sandbox" \
-F "Numbers1=5552001111" \
-F 'FaxQuality=Fine' \
-F 'CSID=(970) 289-5979' \
-F 'CallBackUrl=[GET]http://yourweburl.com/{@jobid}?prod={@prodid}&dir={@dir}' \
-F "Files0=@./your-document.pdf;type=application/pdf"
Numbers1=5552002222 → Call Result Busy after the 2-minute window.
curl -s -X POST "https://integrate.westfax.com/rest/Fax_SendFax/json" \
-H "x-api-key: YOUR_X_API_KEY" \
-F "ProductId=YOUR_PRODUCT_ID" \
-F "JobName=Sandbox Busy" \
-F "Header=From sandbox" \
-F "Numbers1=5552002222" \
-F 'FaxQuality=Fine' \
-F 'CSID=(970) 289-5979' \
-F 'CallBackUrl=[GET]http://yourweburl.com/{@jobid}?prod={@prodid}&dir={@dir}' \
-F "Files0=@./your-document.pdf;type=application/pdf"
Numbers1=5552003333 → Call Result OperatorIntercept after the 2-minute window.
curl -s -X POST "https://integrate.westfax.com/rest/Fax_SendFax/json" \
-H "x-api-key: YOUR_X_API_KEY" \
-F "ProductId=YOUR_PRODUCT_ID" \
-F "JobName=Sandbox Disconnected" \
-F "Header=From sandbox" \
-F "Numbers1=5552003333" \
-F 'FaxQuality=Fine' \
-F 'CSID=(970) 289-5979' \
-F 'CallBackUrl=[GET]http://yourweburl.com/{@jobid}?prod={@prodid}&dir={@dir}' \
-F "Files0=@./your-document.pdf;type=application/pdf"
Numbers1=5552004444 → Call Result Failed after the 2-minute window.
curl -s -X POST "https://integrate.westfax.com/rest/Fax_SendFax/json" \
-H "x-api-key: YOUR_X_API_KEY" \
-F "ProductId=YOUR_PRODUCT_ID" \
-F "JobName=Sandbox Failed" \
-F "Header=From sandbox" \
-F "Numbers1=5552004444" \
-F 'FaxQuality=Fine' \
-F 'CSID=(970) 289-5979' \
-F 'CallBackUrl=[GET]http://yourweburl.com/{@jobid}?prod={@prodid}&dir={@dir}' \
-F "Files0=@./your-document.pdf;type=application/pdf"
Numbers1=5552005555 → Call Result NoAnswer after the 2-minute window.
curl -s -X POST "https://integrate.westfax.com/rest/Fax_SendFax/json" \
-H "x-api-key: YOUR_X_API_KEY" \
-F "ProductId=YOUR_PRODUCT_ID" \
-F "JobName=Sandbox NoAnswer" \
-F "Header=From sandbox" \
-F "Numbers1=5552005555" \
-F 'FaxQuality=Fine' \
-F 'CSID=(970) 289-5979' \
-F 'CallBackUrl=[GET]http://yourweburl.com/{@jobid}?prod={@prodid}&dir={@dir}' \
-F "Files0=@./your-document.pdf;type=application/pdf"
Self-send tip: set Numbers1 to your own fax line 555-200-0000 with a Success last-4 (1111 or any unlisted ending) to also create an inbound fax.
Sample responses
{
"Success": true,
"Result": "f9e8d7c6-b5a4-3210-9876-543210fedcba"
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadProductId",
"InfoString": "Authorization Failed (Bad Product Id)"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Handler_Failed_MissingParameters: Numbers"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Handler_Failed_MissingParameters: Files"
}
Authenticate & fax lines
2 Authenticate
Security_Authenticate — Username (your email) + Password only (no api-key). Session id is throwaway; later calls re-auth each time.
curl -s -X POST "https://integrate.westfax.com/rest/Security_Authenticate/json" \ -d "Username=YOUR_EMAIL" \ -d "Password=YOUR_SIM_PASSWORD"
3 List fax lines
Profile_GetF2EProductList — returns your fax lines. Use a returned Id as ProductId on later calls (that field name is the fax line id). Example uses x-api-key header.
curl -s -X POST "https://integrate.westfax.com/rest/Profile_GetF2EProductList/json" \ -H "x-api-key: YOUR_X_API_KEY"
Sample responses
{
"Success": true,
"Result": [
{
"Id": "YOUR_PRODUCT_ID",
"Name": "555-200-0000",
"ProductType": "FaxForward",
"PlanId": "1fedf262-5042-4f3a-b368-8d975e60d6f7",
"InboundNumber": "5552000000",
"TimeZone": "Pacific",
"ProductState": "OK",
"CurrentBillingPeriodStart": "2026-08-01T00:00:00Z",
"CurrentBillingPeriodEnd": "2026-09-01T00:00:00Z",
"FreeTrialEnd": "2026-11-16T23:59:59Z",
"PeriodicQuantity": 0,
"QuantityInbound": 0,
"QuantityOutbound": 0,
"ShowDeletedItemsFolder": true,
"DefaultCoverPageId": "00000000-0000-0000-0000-000000000000"
},
{
"Id": "YOUR_PRODUCT_ID_2",
"Name": "555-200-0001",
"ProductType": "FaxForward",
"PlanId": "1fedf262-5042-4f3a-b368-8d975e60d6f7",
"InboundNumber": "5552000001",
"TimeZone": "Pacific",
"ProductState": "OK",
"CurrentBillingPeriodStart": "2026-08-01T00:00:00Z",
"CurrentBillingPeriodEnd": "2026-09-01T00:00:00Z",
"FreeTrialEnd": "2026-11-16T23:59:59Z",
"PeriodicQuantity": 0,
"QuantityInbound": 0,
"QuantityOutbound": 0,
"ShowDeletedItemsFolder": true,
"DefaultCoverPageId": "00000000-0000-0000-0000-000000000000"
}
]
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
Get fax data
List fax identifiers
Fax_GetFaxIdentifiers — filter by direction + StartDate.
curl -s -X POST "https://integrate.westfax.com/rest/Fax_GetFaxIdentifiers/json" \ -H "x-api-key: YOUR_X_API_KEY" \ -d "ProductId=YOUR_PRODUCT_ID" \ -d "FaxDirection=Outbound" \ -d "StartDate=1/1/2020"
Sample responses
{
"Success": true,
"Result": [
{
"Id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"Direction": "Outbound",
"Date": "2026-06-15T18:00:00Z",
"Tag": "None"
},
{
"Id": "f9e8d7c6-b5a4-3210-9876-543210fedcba",
"Direction": "Outbound",
"Date": "2026-06-14T12:00:00Z",
"Tag": "Retrieved"
}
]
}
{
"Success": true,
"Result": []
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadProductId",
"InfoString": "Authorization Failed (Bad Product Id)"
}
Get fax descriptions
Fax_GetFaxDescriptions — full status objects (2-minute rule applied at read time).
curl -s -X POST "https://integrate.westfax.com/rest/Fax_GetFaxDescriptions/json" \ -H "x-api-key: YOUR_X_API_KEY" \ -d "ProductId=YOUR_PRODUCT_ID" \ -d "FaxDirection=Outbound" \ -d "StartDate=1/1/2020"
Sample responses
{
"Success": true,
"Result": [
{
"FaxCallInfoList": [
{
"CallId": "11111111-2222-3333-4444-555555555555",
"CompletedUTC": "2026-06-15T18:02:00Z",
"TermNumber": "5552001111",
"OrigNumber": "5552000000",
"TermCSID": "(970) 289-5979",
"OrigCSID": "(970) 289-5979",
"Result": "Sent",
"CallPageCount": 1,
"FilterFlag": 0
}
],
"Id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"Date": "2026-06-15T18:00:00Z",
"Direction": "Outbound",
"Tag": "None",
"PageCount": 1,
"FaxQuality": "Fine",
"Status": "Complete",
"Reference": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"JobName": "Sandbox Sent",
"CreatedBy": "YOUR_EMAIL",
"LoginId": "00000000-0000-0000-0000-000000000000",
"CreatedVia": "ApiRest",
"DocPageCount": 0,
"FilterValue": "None",
"FolderId": "00000000-0000-0000-0000-000000000000",
"FilesAvailable": false,
"ProcessingState": "Final"
}
]
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadProductId",
"InfoString": "Authorization Failed (Bad Product Id)"
}
Paged search
Fax_GetF2EFaxDescriptions_PagedSearch — page/count via MethodParams; optional dates and filters.
curl -s -X POST "https://integrate.westfax.com/rest/Fax_GetF2EFaxDescriptions_PagedSearch/json" \
-H "x-api-key: YOUR_X_API_KEY" \
-d "ProductId=YOUR_PRODUCT_ID" \
-d "FaxDirection=Inbound" \
--data-urlencode 'MethodParams1={"Name":"page","Value":"1"}' \
--data-urlencode 'MethodParams2={"Name":"count","Value":"25"}'
Sample responses
{
"Success": true,
"Result": {
"TotalItems": 1,
"PageNumber": 1,
"ItemsPerPage": 25,
"Items": [
{
"FaxCallInfoList": [
{
"CallId": "11111111-2222-3333-4444-555555555555",
"CompletedUTC": "2026-06-15T18:02:00Z",
"TermNumber": "5552001111",
"OrigNumber": "5552000000",
"TermCSID": "(970) 289-5979",
"OrigCSID": "(970) 289-5979",
"Result": "Success",
"CallPageCount": 1,
"FilterFlag": 0
}
],
"Id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"Date": "2026-06-15T18:00:00Z",
"Direction": "Inbound",
"Tag": "None",
"PageCount": 1,
"FaxQuality": "Fine",
"Status": "Complete",
"Reference": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"JobName": "Sandbox Sent",
"CreatedBy": "System",
"LoginId": "00000000-0000-0000-0000-000000000000",
"CreatedVia": "InboundCall",
"DocPageCount": 0,
"FilterValue": "None",
"FolderId": "00000000-0000-0000-0000-000000000000",
"FilesAvailable": true,
"ProcessingState": "Final",
"FaxId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
}
]
}
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadProductId",
"InfoString": "Authorization Failed (Bad Product Id)"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Handler_Failed_MissingParameters: page,count"
}
Retrieve documents
Fax_GetFaxDocuments — always returns the canonical test PDF (base64 in FileContents). Replace FAX_ID with an Id from Identifiers or Descriptions.
curl -s -X POST "https://integrate.westfax.com/rest/Fax_GetFaxDocuments/json" \
-H "x-api-key: YOUR_X_API_KEY" \
-d "ProductId=YOUR_PRODUCT_ID" \
-d "Format=pdf" \
-d 'FaxIds1={"Id":"FAX_ID"}'
Sample responses
{
"Success": true,
"Result": [
{
"FaxFiles": [
{
"ContentType": "application/pdf",
"ContentLength": 12345,
"FileContents": "<base64 truncated\u2026>"
}
],
"Id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"Direction": "Inbound",
"Date": "2026-06-15T18:00:00Z",
"Status": "Ok",
"Format": "pdf",
"PageCount": 1
}
]
}
{
"Success": true,
"Result": []
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadProductId",
"InfoString": "Authorization Failed (Bad Product Id)"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Handler_Failed_MissingParameters: FaxIds"
}
Descriptions by Id
Fax_GetFaxDescriptionsUsingIds — unknown Ids are silently omitted (empty Result).
curl -s -X POST "https://integrate.westfax.com/rest/Fax_GetFaxDescriptionsUsingIds/json" \
-H "x-api-key: YOUR_X_API_KEY" \
-d "ProductId=YOUR_PRODUCT_ID" \
-d 'FaxIds1={"Id":"FAX_ID"}'
Sample responses
{
"Success": true,
"Result": [
{
"FaxCallInfoList": [
{
"CallId": "11111111-2222-3333-4444-555555555555",
"CompletedUTC": "2026-06-15T18:02:00Z",
"TermNumber": "5552001111",
"OrigNumber": "5552000000",
"TermCSID": "(970) 289-5979",
"OrigCSID": "(970) 289-5979",
"Result": "Sent",
"CallPageCount": 1,
"FilterFlag": 0
}
],
"Id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"Date": "2026-06-15T18:00:00Z",
"Direction": "Outbound",
"Tag": "None",
"PageCount": 1,
"FaxQuality": "Fine",
"Status": "Complete",
"Reference": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"JobName": "Sandbox Sent",
"CreatedBy": "YOUR_EMAIL",
"LoginId": "00000000-0000-0000-0000-000000000000",
"CreatedVia": "ApiRest",
"DocPageCount": 0,
"FilterValue": "None",
"FolderId": "00000000-0000-0000-0000-000000000000",
"FilesAvailable": false,
"ProcessingState": "Final"
}
]
}
{
"Success": true,
"Result": []
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadProductId",
"InfoString": "Authorization Failed (Bad Product Id)"
}
Utilities
Fax usage
Profile_GetFaxUsageByProductId — inbound/outbound counts for a date span (max 32 days) on one fax line. CurrentBillingPeriodStart/End echo the requested range; quantities count sandbox faxes in that window.
curl -s -X POST "https://integrate.westfax.com/rest/Profile_GetFaxUsageByProductId/json" \ -H "x-api-key: YOUR_X_API_KEY" \ -d "ProductId=YOUR_PRODUCT_ID" \ -d "StartDate=6/1/2026 12:00:00AM" \ -d "EndDate=7/1/2026 12:00:00AM"
Sample responses
{
"Success": true,
"Result": {
"Id": "YOUR_PRODUCT_ID",
"Name": "555-200-0000",
"ProductType": "FaxForward",
"PlanId": "1fedf262-5042-4f3a-b368-8d975e60d6f7",
"InboundNumber": "5552000000",
"TimeZone": "Pacific",
"ProductState": "OK",
"CurrentBillingPeriodStart": "2026-06-01T00:00:00Z",
"CurrentBillingPeriodEnd": "2026-07-01T00:00:00Z",
"FreeTrialEnd": "2026-11-16T23:59:59Z",
"PeriodicQuantity": 0,
"QuantityInbound": 51,
"QuantityOutbound": 79,
"ShowDeletedItemsFolder": true,
"DefaultCoverPageId": "00000000-0000-0000-0000-000000000000"
}
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Handler_Failed_MissingParameters: ProductId"
}
{
"Success": false,
"ErrorString": "Api_Failed_",
"InfoString": "Api_Failed_"
}
{
"Success": false,
"ErrorString": "Api_Failed_Action_Not_Allowed",
"InfoString": "Timespan is more than 32 days"
}
Change filter / tag
Fax_ChangeFaxFilterValue — None, Retrieved, or Removed.
curl -s -X POST "https://integrate.westfax.com/rest/Fax_ChangeFaxFilterValue/json" \
-H "x-api-key: YOUR_X_API_KEY" \
-d "ProductId=YOUR_PRODUCT_ID" \
-d "Filter=Retrieved" \
-d 'FaxIds1={"Id":"FAX_ID"}'
Sample responses
{
"Success": true,
"Result": true
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadProductId",
"InfoString": "Authorization Failed (Bad Product Id)"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Handler_Failed_MissingParameters: FaxIds"
}
{
"Success": false,
"ErrorString": "Api_Failed_",
"InfoString": "Api_Failed_"
}
Contacts
List contacts
Contact_GetContactList — what the key can see. Optional ProductId narrows to that fax line (Global + line Public + Private). No update endpoint — edit is save-then-delete. See the Contacts article.
curl -s -X POST "https://integrate.westfax.com/rest/Contact_GetContactList/json" \ -H "x-api-key: YOUR_X_API_KEY" \ -d "Cookies=false"
Sample responses
{
"Success": true,
"Result": [
{
"Id": "11111111-1111-1111-1111-111111111111",
"Title": "",
"FirstName": "Jane",
"LastName": "Doe",
"CompanyName": "Acme Health",
"Email": "",
"EmailValidated": false,
"Fax": "(555) 100-0001",
"MobilePhone": "",
"Phone": "",
"Type": "Global",
"OwnerId": "00000000-0000-0000-0000-000000000001",
"OwnerDisplayName": "ACCT-00000001"
},
{
"Id": "22222222-2222-2222-2222-222222222222",
"Title": "",
"FirstName": "John",
"LastName": "Smith",
"CompanyName": "Example Clinic",
"Email": "john@example.org",
"EmailValidated": false,
"Fax": "5551000002",
"MobilePhone": "",
"Phone": "5551000099",
"Type": "Public",
"OwnerId": "00000000-0000-0000-0000-000000000002",
"OwnerDisplayName": "Shared Line"
},
{
"Id": "33333333-3333-3333-3333-333333333333",
"Title": "",
"FirstName": "Sandra",
"LastName": "Lopez",
"CompanyName": "",
"Email": "",
"EmailValidated": false,
"Fax": "(555) 100-0003",
"MobilePhone": "",
"Phone": "",
"Type": "Private",
"OwnerId": "00000000-0000-0000-0000-000000000003",
"OwnerDisplayName": "YOUR_EMAIL"
}
]
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadProductId",
"InfoString": "Authorization Failed (Bad Product Id)"
}
All contacts
Contact_GetAllContactList — full dump for the account. In this sandbox it matches the unfiltered list (one user per account).
curl -s -X POST "https://integrate.westfax.com/rest/Contact_GetAllContactList/json" \ -H "x-api-key: YOUR_X_API_KEY" \ -d "Cookies=false"
Sample responses
{
"Success": true,
"Result": [
{
"Id": "11111111-1111-1111-1111-111111111111",
"Title": "",
"FirstName": "Jane",
"LastName": "Doe",
"CompanyName": "Acme Health",
"Email": "",
"EmailValidated": false,
"Fax": "(555) 100-0001",
"MobilePhone": "",
"Phone": "",
"Type": "Global",
"OwnerId": "00000000-0000-0000-0000-000000000001",
"OwnerDisplayName": "ACCT-00000001"
},
{
"Id": "22222222-2222-2222-2222-222222222222",
"Title": "",
"FirstName": "John",
"LastName": "Smith",
"CompanyName": "Example Clinic",
"Email": "john@example.org",
"EmailValidated": false,
"Fax": "5551000002",
"MobilePhone": "",
"Phone": "5551000099",
"Type": "Public",
"OwnerId": "00000000-0000-0000-0000-000000000002",
"OwnerDisplayName": "Shared Line"
},
{
"Id": "33333333-3333-3333-3333-333333333333",
"Title": "",
"FirstName": "Sandra",
"LastName": "Lopez",
"CompanyName": "",
"Email": "",
"EmailValidated": false,
"Fax": "(555) 100-0003",
"MobilePhone": "",
"Phone": "",
"Type": "Private",
"OwnerId": "00000000-0000-0000-0000-000000000003",
"OwnerDisplayName": "YOUR_EMAIL"
}
]
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
Send-fax picker (paged)
Contact_GetContactList_ForSend_PagedSearch — requires a fax line ProductId. MethodParams: page, count, optional searchString, filters, includeOnlyContactsWithEmail.
curl -s -X POST "https://integrate.westfax.com/rest/Contact_GetContactList_ForSend_PagedSearch/json" \
-H "x-api-key: YOUR_X_API_KEY" \
-d "ProductId=YOUR_PRODUCT_ID" \
-d "Cookies=false" \
--data-urlencode 'MethodParams1={"Name":"page","Value":"1"}' \
--data-urlencode 'MethodParams2={"Name":"count","Value":"25"}'
Sample responses
{
"Success": true,
"Result": {
"TotalItems": 3,
"PageNumber": 1,
"ItemsPerPage": 25,
"Items": [
{
"Id": "11111111-1111-1111-1111-111111111111",
"Title": "",
"FirstName": "Jane",
"LastName": "Doe",
"CompanyName": "Acme Health",
"Email": "",
"EmailValidated": false,
"Fax": "(555) 100-0001",
"MobilePhone": "",
"Phone": "",
"Type": "Global",
"OwnerId": "00000000-0000-0000-0000-000000000001",
"OwnerDisplayName": "ACCT-00000001"
},
{
"Id": "22222222-2222-2222-2222-222222222222",
"Title": "",
"FirstName": "John",
"LastName": "Smith",
"CompanyName": "Example Clinic",
"Email": "john@example.org",
"EmailValidated": false,
"Fax": "5551000002",
"MobilePhone": "",
"Phone": "5551000099",
"Type": "Public",
"OwnerId": "00000000-0000-0000-0000-000000000002",
"OwnerDisplayName": "Shared Line"
},
{
"Id": "33333333-3333-3333-3333-333333333333",
"Title": "",
"FirstName": "Sandra",
"LastName": "Lopez",
"CompanyName": "",
"Email": "",
"EmailValidated": false,
"Fax": "(555) 100-0003",
"MobilePhone": "",
"Phone": "",
"Type": "Private",
"OwnerId": "00000000-0000-0000-0000-000000000003",
"OwnerDisplayName": "YOUR_EMAIL"
}
]
}
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadProductId",
"InfoString": "Authorization Failed (Bad Product Id)"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Handler_Failed_MissingParameters: page,count"
}
Admin paged search
Contact_GetContactList_ForAdmin_PagedSearch — filters is a comma list: Global,Public,Private.
curl -s -X POST "https://integrate.westfax.com/rest/Contact_GetContactList_ForAdmin_PagedSearch/json" \
-H "x-api-key: YOUR_X_API_KEY" \
-d "Cookies=false" \
--data-urlencode 'MethodParams1={"Name":"page","Value":"1"}' \
--data-urlencode 'MethodParams2={"Name":"count","Value":"50"}' \
--data-urlencode 'MethodParams3={"Name":"filters","Value":"Global,Public"}' \
--data-urlencode 'MethodParams4={"Name":"searchString","Value":"acme"}'
Sample responses
{
"Success": true,
"Result": {
"TotalItems": 1,
"PageNumber": 1,
"ItemsPerPage": 50,
"Items": [
{
"Id": "11111111-1111-1111-1111-111111111111",
"Title": "",
"FirstName": "Jane",
"LastName": "Doe",
"CompanyName": "Acme Health",
"Email": "",
"EmailValidated": false,
"Fax": "(555) 100-0001",
"MobilePhone": "",
"Phone": "",
"Type": "Global",
"OwnerId": "00000000-0000-0000-0000-000000000001",
"OwnerDisplayName": "ACCT-00000001"
}
]
}
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Handler_Failed_MissingParameters: page,count"
}
Save a contact
Contact_SaveContact — always creates (leave Id empty). Only Fax is required inside CrmContact. Type: Global (account), Public (this fax line), Private (one user — set OwnerId if creating for someone else).
curl -s -X POST "https://integrate.westfax.com/rest/Contact_SaveContact/json" \
-H "x-api-key: YOUR_X_API_KEY" \
-d "ProductId=YOUR_PRODUCT_ID" \
-d "Cookies=false" \
--data-urlencode 'CrmContact={"FirstName":"John","LastName":"Test32","Fax":"3032993339","CompanyName":"Acme, LLC","Email":"JTest@acme.org","Phone":"3332223333","Type":"Public"}'
Sample responses
{
"Success": true,
"Result": true
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadProductId",
"InfoString": "Authorization Failed (Bad Product Id)"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Handler_Failed_MissingParameters: CrmContact"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Handler_Failed_MissingParameters: Fax"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Invalid Contact Type"
}
Delete a contact
Contact_DeleteContact — CrmContact needs Id (from a list call) and Type. No email is sent. To “edit”: save the replacement first, then delete the old Id.
curl -s -X POST "https://integrate.westfax.com/rest/Contact_DeleteContact/json" \
-H "x-api-key: YOUR_X_API_KEY" \
-d "Cookies=false" \
--data-urlencode 'CrmContact={"Id":"11111111-1111-1111-1111-111111111111","Type":"Global"}'
Sample responses
{
"Success": true,
"Result": true
}
{
"Success": false,
"ErrorString": "Authorization_Failed_BadUsernamePassword",
"InfoString": "Authorization Failed (Bad Username or Password)"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Handler_Failed_MissingParameters: CrmContact"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Handler_Failed_MissingParameters: Id"
}
{
"Success": false,
"ErrorString": "Handler_Failed_",
"InfoString": "Contact not found"
}