客户 API
目的
此 API 用于获取客户列表,以及用于添加、修改和删除客户。
获取客户 API
此 API 用于获取客户列表。
请求 URL:
https://people.zoho.com.cn/people/api/timetracker/getclients?authtoken=<token>
请求参数:
authtoken | 指定身份验证令牌 |
示例 URL:
https://people.zoho.com.cn/people/api/timetracker/getclients?authtoken=7d985878998943g4j09h43dd0b167dda34b
XML 响应:
<response uri="/api/timetracker/getclients">
<status>0</status>
<message>Data fetched successfully</message>
<result>
<client>
<lastName />
<currencyCode>AFN</currencyCode>
<streetAddr />
<state />
<billingMethod>hourly user rate</billingMethod>
<clientId>281496000000331001</clientId>
<city />
<country>0</country>
<pincode />
<phoneNo />
<compsize>0</compsize>
<emailId />
<description />
<clientName>Google client</clientName>
<faxNo />
<industry />
<firstName />
<mobileNo />
</client>
<client>
<lastName />
JSON 响应:
{ "response": { "message": "Data fetched successfully", "result": [ { "lastName": "", "currencyCode": "AFN", "streetAddr": "", "state": "", "billingMethod": "hourly user rate", "clientId": "281496000000331001", "city": "", "country": "0", "pincode": "", "phoneNo": "", "compsize": 0, "emailId": "", "description": "", "clientName": "Google client", "faxNo": "", "industry": "", "firstName": "", "mobileNo": "" }, "status": 0, "uri": "/api/timetracker/getclients" } }
添加客户 API
此 API 用于添加客户。
请求 URL:
https://people.zoho.com.cn/people/api/timetracker/addclient?authtoken=<token>&clientName=<clientName>¤cy=<currency>&billingMethod=<billingMethod>&firstName=<firstName>&emailId=<emailId>&phoneNo=<phoneNo>&mobileNo=<mobileNo>&faxNo=<faxNo>&city=<city>&state=<state>&pincode=<pincode>&country=<country>&industry=<industry>&compsize=<compsize>&description=<description>
请求参数:
authtoken | 指定身份验证令牌 |
clientName | 指定客户名称 |
currency | 指定货币代码(如:INR 表示印度卢比) |
billingMethod | 指定每小时工作费率或每小时用户费率 |
firstName | 指定名字 |
emailId | 指定邮箱地址 |
phoneNo | 指定电话号码 |
mobileNo | 指定手机号码 |
faxNo | 指定传真号码 |
city | 指定城市 |
state | 指定州/省 |
pincode | 指定个人身份号码 |
country | 指定国家/地区代码(如:IN - 印度) |
industry | 指定行业 |
compsize | 指定公司规模 |
description | 指定描述 |
示例 URL:
people.zoho.com.cn/people/api/timetracker/addclient?authtoken=2110c57f48434f76c22c139c6ef88926&clientName=Google client¤cy=Testigapi&firstName=fname&lastName=lname&emailId=google@gmail.com&phoneNo=958736222&mobileNo=472829292344&faxNo=439987772899&streetAddr=Add_1&city=Ch&state=TN&pincode=600001&country=India&industry=IT&compsize=30&billingMethod=Hourly Job Rate
XML 响应:
<response uri="/api/timetracker/addclient">
<status>0</status>
<message>Client added Successfully</message>
<result>
<clientId>293141000000144015</clientId>
</result>
</response>
JSON 响应:
{ "response": { "message": "Client added Successfully", "result": [ { "clientId": "293141000000144027" } ], "status": 0, "uri": "/api/timetracker/addclient" } }
修改客户 API
此 API 用于修改客户列表。
请求 URL:
https://people.zoho.com.cn/people/api/timetracker/modifyclient?authtoken=<token>&clientId=<clientId>&clientName=<clientName>¤cy=<currency>&billingMethod=<billingMethod>&firstName=<firstName>&lastName=<lastName>&emailId=<emailId>&phoneNo=<phoneNo>&mobileNo=<mobileNo>&faxNo=<faxNo>&city=<city>&state=<state>&pincode=<pincode>&country=<country>&industry=<industry>&compsize=<compsize>&description=<description>
请求参数:
authtoken | 指定身份验证令牌 |
clientId | 指定客户 ID |
clientName | 指定客户名称 |
currency | 指定货币代码 |
billingMethod | 指定每小时工作费率或每小时用户费率 |
firstName | 指定名字 |
lastName | 指定姓氏 |
emailId | 指定邮箱地址 |
phoneNo | 指定电话号码 |
mobileNo | 指定手机号码 |
faxNo | 指定传真号码 |
city | 指定城市 |
state | 指定州/省 |
pincode | 指定个人身份号码 |
country | 指定国家/地区 |
industry | 指定行业 |
compsize | 指定公司规模 |
description | 指定描述 |
示例 URL:
people.zoho.com.cn/people/api/timetracker/modifyclient?authtoken=2110c57f48434f76c22c139c6ef88926&clientId=177402000000814321 &clientName=Google client¤cy=Testigapi&firstName=fname&lastName=lname&emailId=google@gmail.com&phoneNo=958736222&mobileNo=472829292344&faxNo=439987772899&streetAddr=Add_1&city=Ch&state=TN&pincode=600001&country=India&industry=IT&compsize=30&billingMethod=Hourly Job Rate
XML 响应:
<response uri="/api/timetracker/modifyclient">
<status>0</status>
<message>Client modified Successfully</message>
<result>
<clientId>293141000000144015</clientId>
</result>
</response>
JSON 响应:
{ "response": { "message": "Client modified Successfully", "result": [ { "clientId": "293141000000144027" } ], "status": 0, "uri": "/api/timetracker/modifyclient" } }
删除客户 API
此 API 用于删除客户列表。
请求 URL:
https://people.zoho.com.cn/people/api/timetracker/deleteclient?authtoken=<token>&clientId=<clientId>
请求参数:
authtoken | 指定身份验证令牌 |
clientId | 指定客户 ID(用逗号分开) |
示例 URL:
people.zoho.com.cn/people/api/timetracker/deleteclient?authtoken=2110c57f48434f76c22c139c6ef88926&clientId=177402000000814321
XML 响应:
<response uri="/api/timetracker/deleteclient">
<status>0</status>
<message>Client deleted Successfully</message>
<result>
<clientId>293141000000144015</clientId>
</result>
</response>
JSON 响应:
{ "response": { "message": "Client deleted Successfully", "result": [ { "clientId": "293141000000144027" } ], "status": 0, "uri": "/api/timetracker/deleteclient" } }