Get Card

Description

Retrieves your identity card design data structure.

HTTP Method

GET

Path

/cards/identity/{identityId}

Authentication

Does not require user authentication.

Parameters

Table 15.  Parameters for " Get Card "

NameTypeValue TypeDescription
identityIdPATHlongThe identity id for which to retrieve the card data, it has to be an identity belonging to the logged in user.

Error Codes

110000 ( Cards )

An unhanded exception occured.

40005 ( Identity )

Can't retieve the identity information

40007 ( Identity )

Don't have the permission to access the identity.

40015 ( Identity )

The provided ID doesn't point to a valid identity.

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="card">
    <xs:complexType>
      <xs:complexContent>
        <xs:extension base="tns:BaseCard">
          <xs:sequence>
            <xs:element name="campaign" type="xs:string" minOccurs="0"/>
            <xs:element name="line" type="tns:CardLine" maxOccurs="unbounded"/>
          </xs:sequence>
        </xs:extension>
      </xs:complexContent>
    </xs:complexType>
  </xs:element>

  <xs:element name="cardContent">
    <xs:complexType>
      <xs:complexContent>
        <xs:extension base="tns:BaseCard">
          <xs:sequence>
            <xs:element name="line" type="tns:CardContentLine" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
            <xs:element name="socialNetworks">
              <xs:complexType>
                <xs:sequence>
                  <xs:element name="order" type="xs:string"/>
                  <xs:element name="network" type="tns:SNDetail" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
                </xs:sequence>
              </xs:complexType>
            </xs:element>
          </xs:sequence>
        </xs:extension>
      </xs:complexContent>
    </xs:complexType>
  </xs:element>

  <xs:complexType name="BaseCard">
    <xs:sequence>
      <xs:element name="accountId" type="xs:long" minOccurs="0"/>
      <xs:element name="identityId" type="xs:long" minOccurs="0"/>
      <xs:element name="campaignId" type="xs:long" minOccurs="0"/>
      <xs:element name="headerColor" type="xs:string" minOccurs="0"/>
      <xs:element name="textColor" type="xs:string"/>
      <xs:element name="backgroundCardUrl" type="xs:string" minOccurs="0"/>
      <xs:element name="thumbnailUrl" type="xs:string" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="CardLine">
    <xs:sequence>
      <xs:element name="element" type="tns:CardLineElement" maxOccurs="unbounded"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="CardLineElement">
    <xs:sequence>
      <xs:element name="index" type="xs:int" nillable="true"/>
      <xs:element name="osCoordinate" type="tns:OSCoordinateEnum"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="CardContentLine">
    <xs:sequence>
      <xs:element name="elements" type="tns:CardContentLineElement" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="CardContentLineElement">
    <xs:sequence>
      <xs:element name="index" type="xs:int" minOccurs="0"/>
      <xs:element name="osCoordinate" type="tns:OSCoordinateEnum"/>
      <xs:element name="values" type="tns:e" maxOccurs="unbounded"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="e">
    <xs:sequence/>
    <xs:attribute name="key" type="xs:string"/>
    <xs:attribute name="value" type="xs:string"/>
  </xs:complexType>

  <xs:complexType name="SNDetail">
    <xs:sequence>
      <xs:element name="id" type="xs:long"/>
      <xs:element name="nameId" type="xs:string"/>
      <xs:element name="addFriendUrl" type="xs:string"/>
      <xs:element name="viewFriendUrl" type="xs:string"/>
      <xs:element name="loginParameters">
        <xs:complexType>
          <xs:sequence>
            <xs:element name="loginParameter" type="tns:LoginParameter" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
          </xs:sequence>
        </xs:complexType>
      </xs:element>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="LoginParameter">
    <xs:sequence>
      <xs:element name="name" type="xs:string"/>
      <xs:element name="value" type="xs:string"/>
    </xs:sequence>
  </xs:complexType>

  <xs:simpleType name="OSCoordinateEnum">
    <xs:restriction base="xs:string">
      <xs:enumeration value="_Undefined"/>
      <xs:enumeration value="Headline"/>
      <xs:enumeration value="AboutMe"/>
      <xs:enumeration value="Name_Nickname"/>
      <xs:enumeration value="Name_HonorificPrefix"/>
      <xs:enumeration value="Name_GivenName"/>
      <xs:enumeration value="Name_AdditionalName"/>
      <xs:enumeration value="Name_FamilyName"/>
      <xs:enumeration value="Name_Birthday"/>
      <xs:enumeration value="Organization_Name"/>
      <xs:enumeration value="Organization_Title"/>
      <xs:enumeration value="Organization_Department"/>
      <xs:enumeration value="Organization_Industry"/>
      <xs:enumeration value="Organization_Category"/>
      <xs:enumeration value="Organization_Specialty"/>
      <xs:enumeration value="Organization_Region"/>
      <xs:enumeration value="CurrentLocation_StreetAddress"/>
      <xs:enumeration value="CurrentLocation_PostalCode"/>
      <xs:enumeration value="CurrentLocation_Locality"/>
      <xs:enumeration value="CurrentLocation_State"/>
      <xs:enumeration value="CurrentLocation_Country"/>
      <xs:enumeration value="URL"/>
      <xs:enumeration value="Email"/>
      <xs:enumeration value="Phone"/>
    </xs:restriction>
  </xs:simpleType>
</xs:schema>

Sample Response

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<card xmlns="http://xsd.poken.com">
  <accountId>829252</accountId>
  <identityId>829352</identityId>
  <campaignId>123</campaignId>
  <headerColor>#FFFFFF</headerColor>
  <textColor>#515151</textColor>
  <backgroundCardUrl>http://udata.doyoupoken.com/campaign/poken/cardbg.png
  </backgroundCardUrl>
  <line>
    <element>
      <osCoordinate>Name_GivenName</osCoordinate>
    </element>
    <element>
      <osCoordinate>Name_FamilyName</osCoordinate>
    </element>
  </line>
  <line>
    <element>
      <osCoordinate>Name_GivenName</osCoordinate>
    </element>
    <element>
      <osCoordinate>Name_FamilyName</osCoordinate>
    </element>
  </line>
  <line>
    <element>
      <osCoordinate>_Undefined</osCoordinate>
    </element>
  </line>
  <line>
    <element>
      <osCoordinate>CurrentLocation_Country
      </osCoordinate>
    </element>
  </line>
  <line>
    <element>
      <index>0</index>
      <osCoordinate>Email</osCoordinate>
    </element>
  </line>
  <line>
    <element>
      <osCoordinate>_Undefined</osCoordinate>
    </element>
  </line>
  <line>
    <element>
      <osCoordinate>_Undefined</osCoordinate>
    </element>
  </line>
</card>