This API provides an interface for cross-app searches.
The API doesn't define any service info.
{
"relevance": number
}
All messages are JSON objects that have a mandatory attribute "mt" that specifies the message type. Providers must echo the "src" attribute from requests in the corresponding responses.
{
"mt": string,
"src": string
}
This message is sent by the API consumer to start a search request. API providers must respond with 0..n SearchInfo messages followed by a SearchResult message.
{
"mt": "Search",
"src": string,
"search": string,
"type": string
}
Examples:
{
"mt": "Search",
"search": "John Doe",
"type": "contact"
}
{
"mt": "Search",
"search": "Devices",
"type": "app"
}
{
"mt": "Search",
"search": "Marketing"
}
This message is sent by the API provider and contains a single search result result.
{
"mt": "SearchInfo",
"src": string,
"dn": string,
"type": string,
<type>: object,
"link": string,
"relevance": number,
"photourl": string,
"avatar": string
}
This type is used for contacts. The detail object contains the contact details. Note that some search providers add additional attributes to the top level of the message, if the contact corresponds to a PBX user.
{
"mt": "SearchInfo",
"dn": string,
"type": "contact",
"contact": {
"sn": string,
"givenname": string,
"displayname": string,
"title": string,
"position": string,
"department": string,
"company": string,
"telephonenumber": [ string ],
"mobile": [ string ],
"homephone": [ string ],
"extension": [ string ],
"facsimiletelephonenumber": [ string ],
"sip": [ string ],
"email": [ string ],
"url": string,
"description": string,
"info": string,
"roomnumber": string,
"city": string,
"street": string,
"postalcode": string,
"state": string,
"country": string,
"privatecity": string,
"privatestreet": string,
"privatepostalcode": string,
"privatestate": string,
"privatecountry": string
},
"guid": string,
"pbx": string,
"node": string,
"template": string,
"adjust": bool
}
This type is used for apps or pages inside apps. The corresponding detail object has no defined attributes at the moment, so it is empty.
Examples:
{
"mt": "SearchInfo",
"dn": "UsersAdmin",
"type": "app",
"app": {},
"link": "usersadmin",
"relevance": 2000,
"photourl": "http://localhost:10008/appproxy/ext/aps.example.com/example.com/usersapp/innovaphone-usersadmin.png"
}
{
"mt": "SearchInfo",
"dn": "Call diversions",
"type": "app",
"app": {},
"link": "profile?page=call-diversions#d=Call%20diversions",
"relevance": 1000
}
This message is sent by the API provider when the search has been completed and no further SearchInfo messages will be sent.
{
"mt": "SearchResult",
"src": string
}