Retrieve Connection

Description

This method provides a way to retrieve an object connection details. If not called with an authenticated account, just basic information is return

HTTP Method

GET

Path

/object/{objectId}/connection

Authentication

Does not require user authentication.

Parameters

Table 38.  Parameters for " Retrieve Connection "

NameTypeValue TypeDescription
objectIdPATHlongThe id of the object for which to retrieve connection informations.

Error Codes

130006 ( Object )

The oject Id specified does not exist.

150000 ( Common )

An unhandled exception has occured.

Response Schema

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<xs:schema elementFormDefault="qualified" version="1.0" targetNamespace="http://xsd.poken.com" xmlns:tns="http://xsd.poken.com" xmlns:xs="http://www.w3.org/2001/XMLSchema">

  <xs:element name="objectConnection">
    <xs:complexType>
      <xs:complexContent>
        <xs:extension base="tns:BaseObjectConnection">
          <xs:sequence>
            <xs:element name="viewerAccountId" type="xs:long"/>
            <xs:element name="accountId" type="xs:long"/>
            <xs:element name="objectId" type="xs:long"/>
            <xs:element name="collectedCount" type="xs:long" minOccurs="0"/>
            <xs:element name="objectUpdatedDate" type="xs:dateTime" minOccurs="0"/>
          </xs:sequence>
        </xs:extension>
      </xs:complexContent>
    </xs:complexType>
  </xs:element>

  <xs:complexType name="BaseObjectConnection">
    <xs:sequence>
      <xs:element name="type" type="xs:string"/>
      <xs:element name="status" type="xs:string"/>
      <xs:element name="note" type="xs:string"/>
      <xs:element name="keywords" type="tns:Keywords" minOccurs="0"/>
      <xs:element name="firstCollectedDate" type="xs:dateTime" minOccurs="0"/>
      <xs:element name="lastCollectedDate" type="xs:dateTime" minOccurs="0"/>
      <xs:element name="firstViewedDate" type="xs:dateTime" minOccurs="0"/>
      <xs:element name="lastViewedDate" type="xs:dateTime" minOccurs="0"/>
      <xs:element name="latitude" type="xs:double" minOccurs="0"/>
      <xs:element name="longitude" type="xs:double" minOccurs="0"/>
      <xs:element name="favorite" type="xs:boolean" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="Keywords">
    <xs:sequence>
      <xs:element name="keyword" type="xs:string" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
    </xs:sequence>
  </xs:complexType>

  <xs:simpleType name="ConnectionType">
    <xs:restriction base="xs:string">
      <xs:enumeration value="Contact"/>
      <xs:enumeration value="Object"/>
    </xs:restriction>
  </xs:simpleType>

  <xs:simpleType name="ConnectionStatus">
    <xs:restriction base="xs:string">
      <xs:enumeration value="Uncollected"/>
      <xs:enumeration value="New"/>
      <xs:enumeration value="Collected"/>
      <xs:enumeration value="Sponsor"/>
      <xs:enumeration value="Demo"/>
    </xs:restriction>
  </xs:simpleType>
</xs:schema>

Sample Response

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<objectConnection xmlns="http://xsd.poken.com">
  <type>Contact</type>
  <status>New</status>
  <note>this is a note</note>
  <keywords>
    <keyword>tag2</keyword>
    <keyword>tag3</keyword>
    <keyword>tag</keyword>
  </keywords>
  <firstCollectedDate>2012-04-27T13:25:47.595+02:00</firstCollectedDate>
  <lastCollectedDate>2012-04-27T13:25:47.595+02:00</lastCollectedDate>
  <firstViewedDate>2012-04-27T13:46:39.880+02:00</firstViewedDate>
  <lastViewedDate>2012-04-27T14:03:38.843+02:00</lastViewedDate>
  <favorite>true</favorite>
  <viewerAccountId>614323</viewerAccountId>
  <objectId>2018664</objectId>
</objectConnection>