plaxoDownloadsProductsPartnersDevelopersPrivacyHelpAbout UsSign In
Address Book AccessAPIGallery
connect

Sample API Code

Learn from what we've done

Developer Tools

Address Book Access
Give your users access to their up-to-date address book from your website.

Sync API
Synchronize your users' address book.

Where to get help:

Here are some basic examples using the Plaxo API REST binding commands. Currently, they are for reference only—we have more work to do to make them interactive. These commands use a sample test account, devtest@plaxo.com, connected to the Plaxo test server, testapi. To test these commands yourself, create your own account on testapi and replace the Identifier, Password, and ClientID keys in the commands below. When you are trying these on your own account, it's important to remember to update values for keys such as ItemID, FolderID, ServerItemID, etc. with the appropriate values from your account. Check your results by looking at the contacts in your account on testapi. Note that these commands are in a form to drop into a web browser. In practice, it is recommended to use POST instead.

Example 1: Create a unique identifier for your client.
Demonstrates use of CreatGUID command.

The server returns Client ID (GUID) which the client will use in any following calls to the server.

Input:
https://testapi.plaxo.com/rest?package=['Header', 'ProtoVer', '1','Client', 'Dev Clientname/1.0', 'OS', 'windows/service pack infinity', 'Platform', 'Outlook/2005']%0a['/Header']%0a['CreateGUID']%0a['/CreateGUID']
Output:
['Header', 'ProtoVer', '1'] ['/Header'] ['Status', 'Code', '200', 'Message', '200'] ['Item', 'Type', 'GUID'], ['Data', 'GUID', 'PLXI:01000000000002661220152307630149'] ['/Status']
Example 2: Authentication using account devtest@plaxo.com.
Demonstrates use of Identifier, AuthMethod, and Password keys for authenticating in Header command.

Example 3: List the folders in the devtest account.
Demonstrates Get command.

Example 4: Initial Slow Sync from a client with an empty address book (no add) and the server account has one entry "Dev Friend" with a "Home Phone" number.
Demonstrates Sync command and associated Map command.

Example 5: sync scenario of initial slow sync, server data update, subsequent fast sync.
Demonstrates a series of commands: Slow Sync, Map, Ping, contact added to server, Ping, Fast Sync, Map.

Example 6: Handle a special character. (Builds on the previous example)
Demonstrates special character handling of apostrophe.

Example 7: Sync with a delete from the client. (Builds on previous example)
Demonstrates deleting a contact from the client and syncing with the server.

Example 8: Sample error case: client forgets to update the anchors.
Demonstrates an error condition when the client forgets to update the anchors. Client then slow syncs to restore proper synchronization.

Example 9: Sync with similar contact data being merged.
Demonstrates the server merging similar data from the client and server.

Example 10: Syncing to a non-default folder.
Demonstrates Get and Sync commands for specifying the target contacts folder to sync.

Example 11: Multiple subcommands in a sync command.
Demonstrates Sync command with Add, Replace, and Delete.

Terms of Service | Privacy Policy