Skip to content
Snippets Groups Projects
Commit 70f920d2 authored by Seamus Lee's avatar Seamus Lee
Browse files

Update actions based on comment from Coleman re getoptions and add in a note...

Update actions based on comment from Coleman re getoptions and add in a note about not all entities being avaliable
parent 584f9aa4
No related branches found
No related tags found
No related merge requests found
......@@ -20,7 +20,7 @@ Search for records
## getfields
Fetch entity metadata, i.e. the list of fields supported by the entity
Fetch entity metadata, i.e. the list of fields supported by the entity. There is now an option that you can pass in for get fields which is `loadOptions`. This is the equivilant of the apiv3 getoptions API call. When used for any field that specifies a pseudoconstant it will return the relevant options in an options key. You can also pass in an option `IncludeCustom` which will specifiy whether to include the relevant custom fields for that entity or not.
## replace
......
......@@ -11,6 +11,9 @@ Canonically, an API call is processed by the API kernel. The `$entity`, `$actio
A couple of significant differences between APIv4 and APIv3 is that in v4 the `check_permissions` flag is set to true by default and on get actions especially but more generally the limit of 25 items returned that v3 has has been removed in favour of coders specifying the limit if they want to in their code calls.
!!! note
As of October 2019 Not all core entities have been added to apiv4. You should check the API explorer to see what entities are avaliable. If there is not one then please open a pull request to `civicrm-core` repository to add the entity in.
```php
$result = Civi::service('civi_api_kernel')->run('Contact', 'get', [
'version' => 4,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment