diff --git a/docs/api/usage.md b/docs/api/usage.md index ca68c6521d2436e7a45b36ed895ed68dae2b596a..60fcb4ac47aa96d2a1f4fcfbd4dbf478c1c506e0 100644 --- a/docs/api/usage.md +++ b/docs/api/usage.md @@ -222,3 +222,12 @@ cv api contact.get first_name=Alice last_name=Roberts ## API Security API has security mesasures built in depending on the way the API is called that can also be turned off or on. API Permissions are also able to be altered via hook. More information on API Security can be found in the [Security Doucmentation](/security/permissions.md). + +## API Lookups by Username + +You can use a CMS username in lieu of a contact ID by prefacing it with `@user:`. For instance, if the user "james" has a CiviCRM contact ID of 123, these statements are identical: + +```bash +cv api contact.get id=123 +cv api contact.get id=@user:demo +```