概述
欢迎使用 Oranye!通过调用 Oranye API 接口,用户可以使用基础数据查询比对服务。
下面介绍金融 Oranye API 使用方法和计费规则。
授权
Oranye 需要通过使用 Access Key / Secret Key 加密的方法来验证某个请求的发送者身份。Access Key (AK) 用户标示用户,Secret Key (SK) 是用户用于加密认证字符串和金融风控云服务用来验证认证字符串的密钥,其中 SK 必须保密。用户可以使用SDK调用服务或者自行加密。
代码示例请确保将 YOUR_ACCESS_KEY 和 YOUR_SECRET_KEY 替换为你自己的 AK 和 SK。
身份验证不通过样例
{
"status": "NO_AUTHOIZATION",
"transactionId": "196eb0c777789e58",
"message": "出错信息"
}
返回数据格式
响应采用 JSON 格式,包含3个字段
| 参数 | 格式 | 说明 |
|---|---|---|
status |
string |
状态码 |
transactionId |
string |
请求id,最长64位 |
message |
string \ object |
数据 |
状态码
- 无论 API 调用成功还是在过程中发生错误,我们的 API 响应都会返回一个状态码来指示结果。
- 除了全局的状态码外,每个 API 接口都可能有独有的状态码。
- API 用量计费是依照调用接口后的状态码计算的,在这个接口文档中会对每一个状态码标明是否计费,用
计费和免费区分。 - 出现
计费意味着本次 API 调用返回了有效的数据,将会收费 - 出现
免费意味着本次 API 调用没有返回有效数据,将不会收费 - 以下是一些错误原因状态码
| 状态码 | 类型 | 说明 |
|---|---|---|
OK |
计费 |
调用成功 |
INSUFFICIENT_BALANCE |
免费 |
余额不足 |
EXPIRED_REQUEST |
免费 |
请求超时 |
NO_AUTHORIZATION |
免费 |
验证不通过,用户不存在或校验信息有误 |
INVALID_PARAMETER_ERROR |
免费 |
参数校验错误,必填项参数未填 |
RETRY_LATER |
免费 |
系统错误,请稍后重试 |
USER_DISABLED |
免费 |
该用户已被停用 |
APP_DISABLED |
免费 |
该应用已被停用 |
API_DISABLED |
免费 |
该API已被停用 |
OVERDUE_REQUEST |
免费 |
请求过期,传入时间戳距当前系统时间过大 |
身份认证
姓名与身份证号码是否匹配
代码示例
import java.util.HashMap;
import java.util.Map;
import com.oranye.client.*;
public class MainClass {
public static void main(String[] args) {
Client api = new Client("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY");
Map<String, String> data = new HashMap<>();
data.put("name", "HELLO NAME");
data.put("id", "3171024302821001");
String url = "https://api.oranye.co.id/openapi/risk/nik/identity-check/v1";
String response = api.Request(url, data);
System.out.println(response);
}
}
返回数据成功示例
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"id": "3171024302821001",
"name": "HELLO NAME",
"place_of_birth": "BOGOR",
"date_of_birth": "03-02-1982",
"gender": "LAKI-LAKI",
"address": "JL PANGKALAN JATI NO.38",
"province": "DKI JAKARTA",
"city": "JAKARTA TIMUR",
"district": "MAKASAR",
"village": "CIPINANG MELAYU",
"rt": "002",
"rw": "013",
"religion": "ISLAM",
"marital_status": "KAWIN",
"work": "KARYAWAN SWASTA",
"nationnality": "WNI",
"match": true
}
}
返回数据失败示例
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"id": "3171010302820001",
"name": "THIS IS ANOTHER ONE",
"place_of_birth": "BOGOR",
"date_of_birth": "03-02-1982",
"gender": "LAKI-LAKI",
"address": "JL PANGKALAN JATI NO.38",
"province": "DKI JAKARTA",
"city": "JAKARTA TIMUR",
"district": "MAKASAR",
"village": "CIPINANG MELAYU",
"rt": "002",
"rw": "013",
"religion": "ISLAM",
"marital_status": "KAWIN",
"work": "KARYAWAN SWASTA",
"nationnality": "WNI",
"match": false
}
}
人员未查到
{
"status": "PERSON_NOT_FOUND",
"transactionId": "196eb0c777789e58",
"message": "This person can’t be found in our system"
}
HTTP请求
POST https://api.oranye.co.id/openapi/risk/nik/identity-check/v1
请求参数
| 参数 | 必填 | 类型 | 描述 |
|---|---|---|---|
name |
必填 |
string |
认证人员的姓名,最好为全称 |
id |
必填 |
string |
认证人员的身份证号NIK,格式为16位阿拉伯数组 |
返回数据格式
| 参数 | 类型 | 描述 |
|---|---|---|
status |
string |
状态码 |
transactionId |
string |
请求id,最长64位 |
message |
object |
|
id 身份证号码,NIK |
||
name 姓名 |
||
place_of_birth 出生地,可能为空 |
||
date_of_birth 出生日期,可能为空 |
||
gender 性别,可能为空 |
||
address 居住地址,可能为空 |
||
province 省份,可能为空 |
||
city 城市,可能为空 |
||
district 区县,可能为空 |
||
village 村镇,可能为空 |
||
rt 领组,可能为空 |
||
rw 居委会,可能为空 |
||
religion 宗教信仰,可能为空 |
||
marital_status 婚姻状况,可能为空 |
||
work 职业,可能为空 |
||
nationnality 国籍,可能为空 |
||
match 通过根据 id 查询到的 name 与输入的 name 进行对比,一致为true,不一致为 false |
状态码说明
| 状态码 | 类型 | 说明 |
|---|---|---|
OK |
计费 |
查找成功 |
PERSON_NOT_FOUND |
免费 |
没有找到此NIK |
INVALID_ID_NUMBER |
免费 |
输入的身份证号码不合法 |
RETRY_LATER |
免费 |
系统错误,请稍后重试 |
一人多号
根据身份证号,查询身份证号下的电话号列表。根据电话号,查询电话号所属身份证号,以及所属身份证号下的电话号列表。
请求参数示例
import java.util.HashMap;
import java.util.Map;
import com.oranye.client.*;
public class MainClass {
public static void main(String[] args) {
Client api = new Client("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY");
Map<String, String> data = new HashMap<>();
data.put("id", "3171024302821001");
data.put("phone", "+62895806600002");
String url = "https://api.oranye.co.id/openapi/risk/nik/multi-phone-detail/v1";
String response = api.Request(url, data);
System.out.println(response);
}
}
id和phone都能查到结果的应答样例
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"id_info": "+62895806600001,+62895806600002",
"phone_info": [{
"id": "3171024302821001",
"phone": "+62895806600001,+62895806600002"
}]
}
}
输入phone为空或输入phone未查到任何结果的应答样例
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"id_info": "+62895806600001,+62895806600002",
"phone_info": null
}
}
输入的id未查询到结果,输入的phone查询到结果的应答样例
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"id_info": "",
"phone_info": [{
"id": "3171024302821001",
"phone": ""
}]
}
}
输入的phone不合法
{
"status": "INVALID_PHONE_NUMBER",
"transactionId": "196eb0c777789e58",
"message": "Invalid phone number, please check your phone number format"
}
输入的id不合法
{
"status": "INVALID_ID_NUMBER",
"transactionId": "196eb0c777789e58",
"message": "Invalid ID number, please check the NIK format"
}
输入的id和phone所属同一个用户
{
"status": "ALL_FOUND",
"transactionId": "196eb0c777789e58",
"message": {
"id_info": "+6281284500000",
"phone_info": [{
"id": "3216182206820001",
"phone": "+6281284500000"
}]
}
}
输入的id和phone未查询到任何结果的应答样例
{
"status": "NOT_FOUND",
"transactionId": "196eb0c777789e58",
"message": "Id and phone can’t be found in our system"
}
系统错误,请稍后重试
{
"status": "RETRY_LATER",
"transactionId": "196eb0c777789e58",
"message": "Service is not available right now, please try again later"
}
HTTP请求
POST https://api.oranye.co.id/openapi/risk/nik/multi-phone-detail/v1
请求参数
| 参数 | 必填 | 类型 | 描述 |
|---|---|---|---|
id |
可选 |
string |
检测人员的身份证号NIK,格式为16位阿拉伯数组 |
phone |
可选 |
string |
电话号码,格式为国家码 + 号码,例如+62895806600002 |
返回数据格式
| 参数 | 类型 | 描述 |
|---|---|---|
status |
string |
状态码 |
transactionId |
string |
请求id,最长64位 |
message |
object |
|
list: 查询身份证号码下面的手机号 |
状态码说明
| 状态码 | 类型 | 说明 |
|---|---|---|
OK |
计费 |
查找成功 |
INVALID_PHONE_NUMBER |
免费 |
输入的电话号码不合法 |
INVALID_ID_NUMBER |
免费 |
输入的身份证号码不合法 |
ALL_FOUND |
免费 |
输入的身份证和号码所属同一个用户 |
NOT_FOUND |
免费 |
未查询到结果 |
RETRY_LATER |
免费 |
系统错误,请稍后重试 |
号码在网时长
根据电话号码,提供在网时长
请求参数示例
import java.util.HashMap;
import java.util.Map;
import com.oranye.client.*;
public class MainClass {
public static void main(String[] args) {
Client api = new Client("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY");
Map<String, String> data = new HashMap<>();
data.put("phone", "+62895806600002");
String url = "https://api.oranye.co.id/openapi/risk/phone/phone-age/v1";
String response = api.Request(url, data);
System.out.println(response);
}
}
返回数据成功示例
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"days": ">500"
}
}
输入的phone查询不到结果的应答样例
{
"status": "PHONENUMBER_NOT_FOUND",
"transactionId": "196eb0c777789e58",
"message": "This phone number can’t be found in our system"
}
HTTP请求
POST https://api.oranye.co.id/openapi/risk/phone/phone-age/v1
请求参数
| 参数 | 必填 | 类型 | 描述 |
|---|---|---|---|
phone |
必填 |
string |
电话号码,格式为国家码 + 号码,例如+62895806600002 |
返回数据格式
| 参数 | 类型 | 描述 |
|---|---|---|
status |
string |
状态码 |
transactionId |
string |
请求id,最长64位 |
message |
object |
|
days:string 在网时长详情: [0-30],(30-60],(60-90],(90-110],(110-210],(210-365],(365-500],>500 |
状态码说明
| 状态码 | 类型 | 说明 |
|---|---|---|
OK |
计费 |
查找成功 |
INVALID_PHONE_NUMBER |
免费 |
输入的电话号码不合法 |
NOT_FOUND |
免费 |
数据不存在 |
EXPIRED_REQUEST |
免费 |
请求超时 |
号码在网时长V2
根据电话号码,提供在网时长
请求参数示例
import java.util.HashMap;
import java.util.Map;
import com.oranye.client.*;
public class MainClass {
public static void main(String[] args) {
Client api = new Client("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY");
Map<String, String> data = new HashMap<>();
data.put("phone", "+62895806600002");
String url = "https://api.oranye.co.id/openapi/risk/phone/phone-age/v2";
String response = api.Request(url, data);
System.out.println(response);
}
}
返回数据成功示例
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"phone": "+62895806600002",
"age": "2-3month"
}
}
输入的phone查询不到结果的应答样例
{
"status": "PHONENUMBER_NOT_FOUND",
"transactionId": "196eb0c777789e58",
"message": "This phone number can’t be found in our system"
}
HTTP请求
POST https://api.oranye.co.id/openapi/risk/phone/phone-age/v2
请求参数
| 参数 | 必填 | 类型 | 描述 |
|---|---|---|---|
phone |
必填 |
string |
电话号码,格式为国家码 + 号码,例如+62895806600002 |
返回数据格式
| 参数 | 类型 | 描述 |
|---|---|---|
status |
string |
状态码 |
transactionId |
string |
请求id,最长64位 |
message |
object |
|
phone:string 电话号码 |
||
age:string 在网时长详情0-1month、1-2month、2-3month、3-4month、4-5month、5-6month、6-8month、8-10month、10-12month、12month+ |
状态码说明
| 状态码 | 类型 | 说明 |
|---|---|---|
OK |
计费 |
查找成功 |
INVALID_PHONE_NUMBER |
免费 |
输入的电话号码不合法 |
PHONENUMBER_NOT_FOUND |
免费 |
未查询到结果 |
RETRY_LATER |
免费 |
系统错误,请稍后重试 |
号码实名认证
根据电话号码、身份证,提供实名认证关联关系
请求参数示例
import java.util.HashMap;
import java.util.Map;
import com.oranye.client.*;
public class MainClass {
public static void main(String[] args) {
Client api = new Client("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY");
Map<String, String> data = new HashMap<>();
data.put("id", "3171024302821001");
data.put("phone", "+62895806600002");
String url = "https://api.oranye.co.id/openapi/risk/phone/phone-verify/v1";
String response = api.Request(url, data);
System.out.println(response);
}
}
身份证和手机号验证匹配一致
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": "MATCH"
}
身份证和手机号实名验证匹配不一致
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": "NOT_MATCH"
}
未查询到实名认证信息
{
"status": "NOT_FOUND",
"transactionId": "196eb0c777789e58",
"message": "This phone and id can’t be found in our system"
}
HTTP请求
POST https://api.oranye.co.id/openapi/risk/phone/phone-verify/v1
请求参数
| 参数 | 必填 | 类型 | 描述 |
|---|---|---|---|
phone |
必填 |
string |
电话号码,格式为国家码 + 号码,例如+62895806600002 |
id |
必填 |
string |
检测人员的身份证号NIK,格式为16位阿拉伯数组 |
返回数据格式
| 参数 | 类型 | 描述 |
|---|---|---|
status |
string |
状态码 |
transactionId |
string |
请求id,最长64位 |
message |
string |
|
MATCH 或者 NOT_MATCH |
状态码说明
| 状态码 | 类型 | 说明 |
|---|---|---|
OK |
计费 |
查找成功 |
NOT_FOUND |
免费 |
没有找到此电话号码或者NIK |
INVALID_PHONE_NUMBER |
免费 |
输入的电话号码不合法 |
INVALID_ID_NUMBER |
免费 |
输入的身份证号码不合法 |
WhatsApp开通检测
根据输入的号码,检测输入号码的WhatsApp是否开通。
请求参数示例
import java.util.HashMap;
import java.util.Map;
import com.oranye.client.*;
public class MainClass {
public static void main(String[] args) {
Client api = new Client("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY");
Map<String, String> data = new HashMap<>();
data.put("phone", "+62895806600002");
String url = "https://api.oranye.co.id/openapi/risk/phone/is-whatsapp/v1";
String response = api.Request(url, data);
System.out.println(response);
}
}
被查询的号码开通了WhatsApp
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"phone": "+62895806600002",
"whatsapp": "yes"
}
}
被查询的号码未开通WhatsApp
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"phone": "+62895806600002",
"whatsapp": "no"
}
}
被查询的号码未知WhatsApp开通情况
{
"status": "UNKNOWN",
"transactionId": "196eb0c777789e58",
"message": {
"phone": "+62895806600002",
"whatsapp": "checking"
}
}
HTTP请求
POST https://api.oranye.co.id/openapi/risk/phone/is-whatsapp/v1
请求参数
| 参数 | 必填 | 类型 | 描述 |
|---|---|---|---|
phone |
必填 |
string |
电话号码,格式为国家码 + 号码,例如+62895806600002 |
callback |
可选 |
string |
回调URL |
返回数据格式
| 参数 | 类型 | 描述 |
|---|---|---|
status |
string |
状态码 |
transactionId |
string |
请求id,最长64位 |
message |
object |
|
phone:查询的号码 |
||
whatsapp:被查询号码是否开通了whatsapp,yes,no,checking |
请求方式
- callback为空时,当whatsapp值为checking,需要间隔一段时间(>2min)再次发起检测请求
- callback不为空时,一旦查询到结果就返回给回调URL,请不要多次回调同一个号码,多次请求回调对应扣费多次。调用方式为GET https://YOUR_CALLBACKURL/?number=%2B62895806600002&phone=%2B62895806600002&whatsapp=yes
状态码说明
| 状态码 | 类型 | 说明 |
|---|---|---|
OK |
计费 |
查找成功 |
UNKNOWN |
免费 |
未查询到有效数据 不计费 |
INVALID_PHONE_NUMBER |
免费 |
输入的电话号码不合法 |
Facebook开通检测
根据输入的号码,检测输入号码的Facebook是否开通。
请求参数示例
import java.util.HashMap;
import java.util.Map;
import com.oranye.client.*;
public class MainClass {
public static void main(String[] args) {
Client api = new Client("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY");
Map<String, String> data = new HashMap<>();
data.put("phone", "+62895806600002");
data.put("callback", "https://YOUR_CALLBACK_URL");
String url = "https://api.oranye.co.id/openapi/risk/phone/is-facebook/v1";
String response = api.Request(url, data);
System.out.println(response);
}
}
非回调请求(callback为空),被查询的号码开通了Facebook,并且只有一个账号
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"phone": "+62895806600002",
"facebook": "ONE_ACCOUNT"
}
}
非回调请求(callback为空),被查询的号码开通了Facebook,并且有多个账号
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"phone": "+62895806600002",
"facebook": "MULTIPLE_ACCOUNT"
}
}
非回调请求(callback为空),被查询的号码Facebook账户不可用
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"phone": "+62895806600002",
"facebook": "ACCOUNT_DISABLED"
}
}
非回调请求(callback为空), 被查询的号码未开通Facebook
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"phone": "+62895806600002",
"facebook": "NO_ACCOUNT"
}
}
非回调请求(callback为空), 被查询的号码正在查询中
{
"status": "UNKNOWN",
"transactionId": "196eb0c777789e58",
"message": {
"phone": "+62895806600002",
"facebook": "checking"
}
}
通过回调地址进行返回(callback地址)
GET https://YOUR_CALLBACKURL/?number=%2B62895806600002&phone=%2B62895806600002&facebook=ONE_ACCOUNT
HTTP请求
POST https://api.oranye.co.id/openapi/risk/phone/is-facebook/v1
请求参数
| 参数 | 必填 | 类型 | 描述 |
|---|---|---|---|
phone |
必填 |
string |
电话号码,格式为国家码 + 号码,例如+62895806600002 |
callback |
可选 |
string |
回调URL |
返回数据格式
| 参数 | 类型 | 描述 |
|---|---|---|
status |
string |
状态码 |
transactionId |
string |
请求id,最长64位 |
message |
object |
|
phone:查询的号码 |
||
facebook:被查询号码是否开通了facebook |
请求方式
- callback为空时,当facebook值为checking,需要间隔一段时间(>2min)再次发起检测请求
- callback不为空时,一旦查询到结果就返回给回调URL,请不要多次回调同一个号码,多次请求回调对应扣费多次。调用方式为GET https://YOUR_CALLBACKURL/?number=%2B62813116594289&phone=%2B62813116594289&facebook=ONE_ACCOUNT
状态码说明
| 状态码 | 类型 | 说明 |
|---|---|---|
OK |
计费 |
查找成功 |
UNKNOWN |
免费 |
未查询到有效数据 不计费 |
INVALID_PHONE_NUMBER |
免费 |
输入的电话号码不合法 |
RETRY_LATER |
免费 |
系统错误,请稍后重试 |
多头查询-NIK
根据身份证,提供查询贷款机构的数量。
请求参数示例
import java.util.HashMap;
import java.util.Map;
import com.oranye.client.*;
public class MainClass {
public static void main(String[] args) {
Client api = new Client("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY");
Map<String, String> data = new HashMap<>();
data.put("id", "3171024302821001");
String url = "https://api.oranye.co.id/openapi/risk/nik/multi-platform-detail/v1";
String response = api.Request(url, data);
System.out.println(response);
}
}
能查到结果的应答样例
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"07d": 0,
"14d": 1,
"21d": 1,
"30d": 2,
"60d": 4,
"90d": 11,
"total": 11
}
}
请求参数错误
{
"status": "FAIL",
"transactionId": "196eb0c777789e58",
"message": "Invalid id, please check your id format"
}
服务器内部错误
{
"status": "RETRY_LATER",
"transactionId": "196eb0c777789e58",
"message": "Service is not available right now, please try again later"
}
HTTP请求
POST https://api.oranye.co.id/openapi/risk/nik/multi-platform-detail/v1
请求参数
| 参数 | 必填 | 类型 | 描述 |
|---|---|---|---|
id |
必填 |
string |
认证人员的身份证号NIK,格式为16位阿拉伯数组 |
返回数据格式
| 参数 | 类型 | 描述 |
|---|---|---|
status |
string |
状态码 |
transactionId |
string |
请求id,最长64位 |
message |
object |
|
07d: 7天之内查询贷款机构的数量 |
||
14d: 14天之内查询贷款机构的数量 |
||
21d: 21天之内查询贷款机构的数量 |
||
30d: 30天之内查询贷款机构的数量 |
||
60d: 60天之内查询贷款机构的数量 |
||
90d: 90天之内查询贷款机构的数量 |
||
total: 查询贷款机构的总数量 |
状态码说明
| 状态码 | 类型 | 说明 |
|---|---|---|
OK |
计费 |
查找成功 |
INVALID_ID_NUMBER |
免费 |
输入的身份证号码不合法 |
RETRY_LATER |
免费 |
系统错误,请稍后重试 |
多头查询-PHONE
电话号码,提供查询贷款机构的数量。
请求参数示例
import java.util.HashMap;
import java.util.Map;
import com.oranye.client.*;
public class MainClass {
public static void main(String[] args) {
Client api = new Client("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY");
Map<String, String> data = new HashMap<>();
data.put("phone", "+62895806600002");
String url = "https://api.oranye.co.id/openapi/risk/phone/multi-platform-detail/v1";
String response = api.Request(url, data);
System.out.println(response);
}
}
能查到结果的应答样例
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"07d": 0,
"14d": 1,
"21d": 1,
"30d": 2,
"60d": 4,
"90d": 11,
"total": 11
}
}
请求参数错误
{
"status": "FAIL",
"transactionId": "196eb0c777789e58",
"message": "Invalid phone number, please check your phone format"
}
服务器内部错误
{
"status": "RETRY_LATER",
"transactionId": "196eb0c777789e58",
"message": "Service is not available right now, please try again later"
}
HTTP请求
POST https://api.oranye.co.id/openapi/risk/phone/multi-platform-detail/v1
请求参数
| 参数 | 必填 | 类型 | 描述 |
|---|---|---|---|
phone |
必填 |
string |
电话号码,格式为国家码 + 号码,例如+62895806600002 |
返回数据格式
| 参数 | 类型 | 描述 |
|---|---|---|
status |
string |
状态码 |
transactionId |
string |
请求id,最长64位 |
message |
object |
|
07d: 7天之内查询贷款机构的数量 |
||
14d: 14天之内查询贷款机构的数量 |
||
21d: 21天之内查询贷款机构的数量 |
||
30d: 30天之内查询贷款机构的数量 |
||
60d: 60天之内查询贷款机构的数量 |
||
90d: 90天之内查询贷款机构的数量 |
||
total: 查询贷款机构的总数量 |
状态码说明
| 状态码 | 类型 | 说明 |
|---|---|---|
OK |
计费 |
查找成功 |
INVALID_PHONE_NUMBER |
免费 |
输入的电话号码不合法 |
RETRY_LATER |
免费 |
系统错误,请稍后重试 |
充值行为
根据电话号码,返回用户的充值行为特征。
请求参数示例
import java.util.HashMap;
import java.util.Map;
import com.oranye.client.*;
public class MainClass {
public static void main(String[] args) {
Client api = new Client("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY");
Map<String, String> data = new HashMap<>();
data.put("phone", "+62895806600002");
String url = "https://api.oranye.co.id/openapi/risk/phone/top-up/v1";
String response = api.Request(url, data);
System.out.println(response);
}
}
输入的phone查询到结果的应答样例
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": [
{
"timeSlice": "1-90d",
"depositCount": 3,
"avgDeposit": "10000.00"
},
{
"timeSlice": "91-180d",
"depositCount": 3,
"avgDeposit": "3000.00"
},
{
"timeSlice": "181-360d",
"depositCount": 0,
"avgDeposit": "0.00"
}
]
}
输入的phone查询不到结果的应答样例
{
"status": "PHONENUMBER_NOT_FOUND",
"transactionId": "196eb0c777789e58",
"message": "This phone number can’t be found in our system"
}
服务器内部错误
{
"status": "RETRY_LATER",
"transactionId": "196eb0c777789e58",
"message": "Service is not available right now, please try again later"
}
HTTP请求
POST https://api.oranye.co.id/openapi/risk/phone/top-up/v1
请求参数
| 参数 | 必填 | 类型 | 描述 |
|---|---|---|---|
phone |
必填 |
string |
电话号码,格式为国家码 + 号码,例如+62895806600002 |
返回数据格式
| 参数 | 类型 | 描述 |
|---|---|---|
status |
string |
状态码 |
transactionId |
string |
请求id,最长64位 |
message |
object |
|
timeSlice: 时间段分为1-90d、91-180d、181-360d |
||
depositCount: 充值次数 |
||
avgDeposit: 平均充值金额 |
状态码说明
| 状态码 | 类型 | 说明 |
|---|---|---|
OK |
计费 |
查找成功 |
INVALID_PHONE_NUMBER |
免费 |
输入的电话号码不合法 |
PHONENUMBER_NOT_FOUND |
免费 |
未查询到结果 |
RETRY_LATER |
免费 |
系统错误,请稍后重试 |
充值行为V2
根据电话号码,返回用户的充值行为特征。
请求参数示例
import java.util.HashMap;
import java.util.Map;
import com.oranye.client.*;
public class MainClass {
public static void main(String[] args) {
Client api = new Client("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY");
Map<String, String> data = new HashMap<>();
data.put("phone", "+62895806600002");
String url = "https://api.oranye.co.id/openapi/risk/phone/top-up/v2";
String response = api.Request(url, data);
System.out.println(response);
}
}
输入的phone查询到结果的应答样例
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"topup_0_30": {
"avg": 10,
"times": 5,
"max": 10,
"min": 10
},
"topup_0_60": {
"avg": 9,
"times": 10,
"max": 10,
"min": 5
},
"topup_0_90": {
"avg": 11,
"times": 17,
"max": 50,
"min": 5
},
"topup_0_180": {
"avg": 10,
"times": 20,
"max": 50,
"min": 5
},
"topup_0_360": {
"avg": 7,
"times": 61,
"max": 50,
"min": 5
},
"topup_30_60": {
"avg": 9,
"times": 5,
"max": 10,
"min": 5
},
"topup_60_90": {
"avg": 13,
"times": 7,
"max": 50,
"min": 5
},
"topup_90_180": {
"avg": 8,
"times": 3,
"max": 10,
"min": 5
},
"topup_180_360": {
"avg": 5,
"times": 41,
"max": 10,
"min": 5
},
"topup_360_720": {
"avg": 6,
"times": 54,
"max": 10,
"min": 5
}
}
}
输入的phone查询不到结果的应答样例
{
"status": "PHONENUMBER_NOT_FOUND",
"transactionId": "196eb0c777789e58",
"message": "This phone number can’t be found in our system"
}
服务器内部错误
{
"status": "RETRY_LATER",
"transactionId": "196eb0c777789e58",
"message": "Service is not available right now, please try again later"
}
HTTP请求
POST https://api.oranye.co.id/openapi/risk/phone/top-up/v2
请求参数
| 参数 | 必填 | 类型 | 描述 |
|---|---|---|---|
phone |
必填 |
string |
电话号码,格式为国家码 + 号码,例如+62895806600002 |
返回数据格式
| 参数 | 类型 | 描述 |
|---|---|---|
status |
string |
状态码 |
transactionId |
string |
请求id,最长64位 |
message |
object |
|
topup_时间区间: 划分为11个时间区间分别为0~30天、0~60天、0~90天、0~180天、0~360天、30~60天、60~90天、90~180天、180~360天、360天~720天 |
||
avg: 平均充值消费能力 |
||
times: 充值消费频次 |
||
max: 最大充值消费能力 |
||
min: 最小充值消费能力 |
状态码说明
| 状态码 | 类型 | 说明 |
|---|---|---|
OK |
计费 |
查找成功 |
INVALID_PHONE_NUMBER |
免费 |
输入的电话号码不合法 |
PHONENUMBER_NOT_FOUND |
免费 |
未查询到结果 |
RETRY_LATER |
免费 |
系统错误,请稍后重试 |
兴趣偏好
根据电话号码,返回用户的兴趣偏好
请求参数示例
import java.util.HashMap;
import java.util.Map;
import com.oranye.client.*;
public class MainClass {
public static void main(String[] args) {
Client api = new Client("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY");
Map<String, String> data = new HashMap<>();
data.put("phone", "+62895806600002");
String url = "https://api.oranye.co.id/openapi/risk/phone/preference/v1";
String response = api.Request(url, data);
System.out.println(response);
}
}
输入的phone查询到结果的应答样例
{
"status": "OK",
"transactionId": "196eb0c777789e58",
"message": {
"bank": {
"060d": 5,
"090d": 6,
"180d": 7,
"270d": 10
},
"ecommerce": {
"060d": 165,
"090d": 176,
"180d": 215,
"270d": 224
},
"game": {
"060d": 5,
"090d": 6,
"180d": 62,
"270d": 165
},
"lifestyle": {
"060d": 68,
"090d": 104,
"180d": 215,
"270d": 303
}
}
}
输入的phone查询不到结果的应答样例
{
"status": "PHONENUMBER_NOT_FOUND",
"transactionId": "196eb0c777789e58",
"message": "This phone number can’t be found in our system"
}
服务器内部错误
{
"status": "RETRY_LATER",
"transactionId": "196eb0c777789e58",
"message": "Service is not available right now, please try again later"
}
HTTP请求
POST https://api.oranye.co.id/openapi/risk/phone/preference/v1
请求参数
| 参数 | 必填 | 类型 | 描述 |
|---|---|---|---|
phone |
必填 |
string |
电话号码,格式为国家码 + 号码,例如+62895806600002 |
返回数据格式
| 参数 | 类型 | 描述 |
|---|---|---|
status |
string |
状态码 |
transactionId |
string |
请求id,最长64位 |
message |
object |
|
类目: 划分为4个分类,分别为bank、ecommerce、game、lifestyle |
||
时间段: 划分为4个时间区间分别为过去0~60天、0~90天、0~180天、0~270天 |
状态码说明
| 状态码 | 类型 | 说明 |
|---|---|---|
OK |
计费 |
查找成功 |
INVALID_PHONE_NUMBER |
免费 |
输入的电话号码不合法 |
PHONENUMBER_NOT_FOUND |
免费 |
未查询到结果 |
RETRY_LATER |
免费 |
系统错误,请稍后重试 |