get_modified_relationships
Overview
Retrieves a list of modified relationships between a specific date range. Helps facilitate sync operations for users.
Available APIs
- SOAP
- REST
Definition
get_modified_relationships(session, module_name, related_module, from_date, to_date, offset, max_results, deleted, module_user_id, select_fields, relationship_name, deletion_date)
Parameters
| Name | Type | Description |
|---|---|---|
| session | String | Session ID returned by a previous login call. |
| module_name | String | The module key to retrieve relationships against. |
| related_module | String | The related module key to retrieve records off of. This parameter should always be 'Users'. |
| from_date | String | Start date in YYYY-MM-DD HH:MM:SS format for the date range. |
| to_date | String | End date in YYYY-MM-DD HH:MM:SS format for the date range. |
| offset | Integer | The offset to begin returning records from. |
| max_results | Integer | The max_results to return. |
| deleted | Integer | Whether or not to include deleted records. Set to 1 to find deleted records. |
| module_user_id | String | *This parameter is no longer used and is only present for backward compatibility purposes. |
| select_fields | select_fields | List of fields to select and return as name/value pairs. |
| relationship_name | String | The name of the relationship name to search on. |
| deletion_date | String |
Date value in YYYY-MM-DD HH:MM:SS format for filtering on deleted records whose date_modified falls within range.
|
Result
| Name | Type | Description |
|---|---|---|
| result | modified_relationship_result | Array | The call result. |
| result.result_count | Integer | The result count. |
| result.next_offset | Integer | The next offset to retrieve from. |
| result.entry_list | Array | List of found records. |
| result.error | Array | Error Message. |
| result.error.number | Integer | The error number. |
| result.error.name | String | The name of the error. |
| result.error.description | String | The description of the error. |
Change Log
| Version | Change | |
|---|---|---|
| v4_1 | Added get_modified_relationships method. | |
Considerations
-
The module_name parameter should always be 'Users'.
Examples
PHP
$get_modified_relationships_parameters = array(
//Session id
'session' => $session_id,
//The module key to retrieve relationships against.
//This parameter should always be 'Users'.
'module_name' => 'Users',
//The related module key to retrieve records off of.
'related_module' => 'Meetings',
//Start date in YYYY-MM-DD HH:MM:SS format for the date range.
'from_date' => '2000-01-01 01:01:01',
//End date in YYYY-MM-DD HH:MM:SS format for the date range
'to_date' => '2013-01-01 01:01:01',
//The offset to begin returning records from.
'offset' => 0,
//The max_results to return.
'max_results' => 5,
//Whether or not to include deleted records. Set to 1 to find deleted records.
'deleted' => 0,
//This parameter is not used.
'module_user_id' => '',
//List of fields to select and return as name/value pairs.
'select_fields' => array(),
//The name of the relationship name to search on.
'relationhip_name' => 'meetings_users',
//Date value in YYYY-MM-DD HH:MM:SS format for filtering on deleted records.
'deletion_date' => '2012-01-01 01:01:01'
);