Allegro WebAPI

Programming interface of the Allegro platform


Last change: ---
This method is for getting purchase transactions you can request the commission refund form.

  1. sessionId | string | required
    User's session identifier received using the doLogin(Enc) method.
  2. filterOptions | FilterOptionsType[] | non-required
    Criteria of filtering the results (a list of available in that certain context filters is returned as the output of the method within the  filtersList structure).
    1. filterId | string | non-required
      Filter ID.
    2. filterValueId | string[] | non-required
      ID(s) of a filter’s value (single of multiple filters).
    3. filterValueRange | RangeValueType | non-required
      The scope of a filter’s value (for range filters).
      1. rangeValueMin | string | non-required
        Minimum filter value.
      2. rangeValueMax | string | non-required
        Maximum filter value.
  3. sortOrder | string | non-required
    Sorting order: asc - ascending (default value for most of the listings), desc - descending.
  4. resultSize | int | non-required
    Size of data portion (min. 1, max. 1,000). Default value: 100.
  5. resultOffset | int | non-required
    Controlling the process of getting another portion of data. Default value: 0.

Sample structure of method call

$dogetrefundsdeals_request = array(
   'sessionId' => '22eb99326c6be29aa16d07d622bcfbcbee94ad54846f2f4e03_1',
   'filterOptions' => array(
      'filterId' => 'itemId',
      'filterValueId' => array('3199800297'))),

  1. dealsCount | int
    Number of all purchase transactions (matching the query).
  2. dealsList | RefundListType[]
    Array of structures containing information on purchase transactions. The returned list starts with the oldest purchase transaction.
    1. dealId | int
      Identifier of a purchase transaction.
    2. dealDate | dateTime
      Date of purchase transaction.
    3. timeLeft | int
      Remaining time for filling in the commission refund form (expressed in days).
    4. buyerId | int
      Buyer ID.
    5. buyerLogin | string
      Buyer username.
    6. itemId | long
      Offer ID
    7. itemTitle | string
      Offer title.
    8. bidsCount | int
      Number of items bought.
    9. quantityType | string
      Type of available items: pieces, sets or pairs.
    10. paymentStatus | string
      Payment status (complete - paid, missing - no payment, cod - COD, without_payu - no information on payment).
  3. filtersList | FilterListType[]
    Information on filters available in the given context.
    1. filterId | string
      Filter ID.
    2. filterName | string
      Filter name.
    3. filterType | string
      Filter type: country - global filter for the given site/country, category - filter existing only within the passed category (parameter).
    4. filterControlType | string
      Indicator type required to display a filter: combobox (a single value on a list), checkbox (multiple options on a list), textbox (values to be provide manually).
    5. filterDataType | string
      Type of data accepted by a filter: string, int, long, float and datetime.
    6. filterIsRange | boolean
      Information whether a parameter is of range type: true/false.
    7. filterArraySize | int
      Maximum number of values that can be passed for a certain filter (returned only for multiple filters).
    8. filterValues | FilterValueType[]
      Information on the values of filters.
      1. filterValueId | string
        ID of a filter’s value.
      2. filterValueName | string
        Name of a filter’s value (to be displayed by an application).
      3. filterValueCount | int
        Number of offers matching the given filter (returned if it is possible to count it in the given context).
    9. filterRelations | FilterRelationType
      Information on relations between the filters.
      1. relationAnd | string[]
        List of all filter IDs the given filter  must be used with.
      2. relationOr | string[]
        List of filter IDs –  at least one  must  be used with the given filter.
      3. relationExclude | string[]
        List of filter IDs which the given filter cannot  be used with.

Sample structure of server reply

$dogetrefundsdeals_response = array(
   'dealsCount' => 1,
   'dealsList' => array(
        'dealId' => 987121979,
        'dealDate' => 2013-12-18 13:08:16,
        'timeLeft' => 1,
        'buyerId' => 5921761,
        'buyerLogin' => 'testaccount',
        'itemId' => 3136513627,
        'itemTitle' => 'Witcher',
        'bidsCount' => 1,
        'quantityType' => 'pieces',
        'paymentStatus' => 'complete')),
   'filtersList' => array(
        'filterId' => 'itemId',
        'filterName' => 'Offer ID',
        'filterType' => 'country',
        'filterControlType' => 'textbox',
        'filterDataType' => 'long',
        'filterIsRange' => false,
        'filterRelations' => array(
             'relationExclude' => array('userLogin'))),
        'filterId' => 'userLogin',
        'filterName' => 'Username',
        'filterType' => 'country',
        'filterControlType' => 'textbox',
        'filterDataType' => 'string',
        'filterIsRange' => false,
        'filterRelations' => array(
             'relationExclude' => array('itemId'))))

    Filter cannot be used with one of provided filterslist of filters.
    Incorrect value of a filter value’s ID (for a single, multiply or range filter).
    Incorrect offset value (lower than 0).
    Incorrect value of a data portion size (exceeds the 1-1,000 range).
    Incorrect value of a sorting order.
    This method is available only in the user’s country.
    Invalid session identifier or the session has expired.

Allegro is not to be held liable for consequences of using examples of the published code. It does not guarantee its correct operation either. The code you see serves as an example only and may contain errors.