User Tools

Site Tools


en:public:developer:template_system:tags:api:add_lead

This is an old revision of the document!


<#Add_Lead>

Use this function to add a lead in the database. This function must be called only from cfgpages

CfgPages configuration

  <page name="My_Add_lead_Api_Function">
    <cfg>
      <userrights>
	<userright name="ALLUSER"/>
      </userrights>
      <frames>
	<frame name="mainframe" processname="Add_lead" preload="1"/>
      </frames>
    </cfg>
  </page>

RESTful API

The ArKadia API currently supports a RESTful interface, that essentially means you can send an HTTP GET or POST to call exposed methods, and you'll get back an XML document in return.

When you call this function, you'll get a response in XML that looks like this:

<rsp stat="ok" version="1.0">
  [Data in XML format - see individual method docs]
</rsp>

If there's an error, you'll get a response with an error message about the problem.

<rsp stat="fail">
  <error msg="Error Message" />
<rsp>

HTTP Get/Post Parameters

Name Mandatory Default Description
Property.ID No ID of the property on with the lead will be linked
lead.type Yes Type of lead (1=Email ; 2=Web ; 3=Alerte ; 4=Telephone)
Buyer.id No ID of the Web user ID of the buyer

Error Codes

Code Description
111 One mandatory parameter is missing

Example



en/public/developer/template_system/tags/api/add_lead.1358153116.txt.gz · Last modified: 2013/01/14 12:45 by admin