-
Notifications
You must be signed in to change notification settings - Fork 66
Create Contact
corsacca edited this page Feb 19, 2018
·
14 revisions
In code Create contact funtion
create_contact( array $fields = [], $check_permissions = true )
- fields: an array of fields like name, phone number corresponding to the new contact. More details below.
- check_permissions: check if the signed in user has the permission to perform this action. By default this should be true, unless this is called by an automated process.
- url:
https://example.com/wp-json/dt/v1/contact/create - type: POST
- data: A JSON string of fields
- contentType: "application/json; charset=UTF-8",
- dataType: "json",
Fields have different types. Each type will need it's own syntax.
-
Text
- name
-
key_select
- overall_status
- seeker_path
The options for each of these can be found in the Contact Post Type page
fields = [
overall_status => "established"
]
$fields = [
]