I'm facing problem while importing and exporting the contacts from PHP to Constant Contact.
Can any one provide me the eample xml format to execute in REST client and also provide the guide lines what headers and method to use while executing the xml using REST client.
You are looking to use the bulk upload activity route for your export and import, right? The following details are for the bulk export:
In restclient, you will make a GET request to the URI: https://api.constantcontact.com/ws/customers/username/activities (replacing username with your username).
The header Key will be "Content-type" and the value will be "application/x-www-form-urlencoded"
You can use basic authentication, or whatever you usually use in restclient. That should be all you need to create the exported list. The body of the response will contain a link to the exported list, if the call is successful. We do have more information about that here.
For the import, this page should have all the information you need; your call will change based on whether you want to import from a file or encode your contact details.
I hope that helps! Let us know if you keep encountering issues.