1. I have corrected the e-mail settings so that outgoing e-mails from these forums should be sent now. If you tried to Register or Reset your Password, please try again!
    Dismiss Notice

Common Issues

Discussion in 'Census: Developer Announcements' started by DanKinney, Jan 4, 2012.

  1. DanKinney

    DanKinney Guest

    This thread is intended to highlight common misconceptions or mistakes that are being made using data from the feeds.

    This is an open, sticky thread for folks to share their experience.

    -dan

     
  2. DanKinney

    DanKinney Guest

    In common syntax, optional values in the documentation are represented in [brackets].  That means that they are optional, but show the syntax when they are used.

    A common misuse of this is with the c:sort query command.  For example, the usage is defined as...

    Code:
    c:sort=field[:1,:-1]
    However, this use will not work and will return an error:

    <span style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px;">/xml/get/eq2/character/?c:show=pvp.title_rank&c:sort=pvp.title_rank[:-1]

    This query should look like...

    <span style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px;">/xml/get/eq2/character/?c:show=pvp.title_rank&c:sort=pvp.title_rank:-1

    (no brackets)

    -dan

     
  3. DanKinney

    DanKinney Guest

    When making a query to the API, you can include a number of Query String variables that allow you to search for objects that match various criteria.

    /yaml/get/eq2/character/?name.first=Dareki

    In the results, you will find the character ID, from this example: 863289283327

    So, you could "search" for this character by this id...

    /yaml/get/eq2/character/?id=863289283327

    However, the URL (if you know the ID) is much cleaner as...

    /yaml/get/eq2/character/863289283327

    You can then apply a Query Command on this, such as...

    /yaml/get/eq2/character/863289283327?c:show=displayname&c:attachments=all

    This pattern works across all collections available on the API.  If you have the ID of an object within a collection, go ahead an use that ID within the base URL.

     

Share This Page