Skip to end of metadata
Go to start of metadata

asariAPI

Icon

The data downloaded by API should be saved to a local database. Web pages should display data from database prepared in that way.

Number of queries to the API is restricted to 25 per minute (It's best to use a 3-4 second interval). Limit of connection can undergo change.

 

Introduction

Api methods serve http calls responding with json (http://www.json.org/). Methods for website creation are described in Site section.

Authentication via Token

To autheniticate you need id of user and unique token. loginToken and userId should be sent with other parameters of request. F.ex.

Parameter types

Parameter in method calls should be formated as following

Type

Format

Examples

integer

number

123345
0

float

decimal part separated by comma or period

123.4343
or
123,4323

date

yyyy-MM-dd
or
yyyy-MM-dd hh:mm:ss
(short format will be translated to yyyy-MM-dd 00:00:00)

2010-12-31
2010-12-31 18:55:58

string

text

bla bla bla

boolean

true
empty value for false

 

dictionary

string value representing given dictionary value (listed below)

Active
House

Pagination and sorting

Some methods returning list of objects allow pagination. Following paramterers should be applied (If no max(limit) provided system will automatically set parameter to reasonable value).

Parameter

Type

Description

offset
or
start

integer

return result starting from row (0 based)

max
or
limit

integer

max number of rows to return

Sorting can be obtained by providng following parameters. Both parameters should be sent.

Parameter

Type

Description

sort

string

name of property

order

string

'asc' or 'desc'

Response format

Every response object has property:

  • success (boolean) - determaining if response is valid or error occured.

Success Response

Json object with properties:

  • data (object or array of objects)
  • totalCount (integer) - returned if data is array and method enables pagination

Example simple object:

Example list:

Error Response

Json object with properties:

  • error (string) - error message in human readable format (localized)
  • parametersErrors (object where properties are names of parameters and values are error messages related to given parameter) - returned if error is related to input parameters. F.ex. can be used as error messages for forms submitted by user.

Example error:

Example error with parameter errors:

Return types

Method will return json object with following properties (more info http://www.json.org/ )

Type

Format

Example

string

text

"bla bla bla"

integer

number

3242

float

decimal part separated by period

3232.3232

date

text in format yyyy-MM-dd hh:mm:ss

"2010-12-31 18:55:58"

boolean

true, false

 

money

object

Dictionaries

Name

Values

FieldType

string, integer, float, date, boolean, money, dictionary, dictionaryList

View

show, edit, list, search

Section

ApartmentSale, ApartmentRental, HouseSale, HouseRental, LotSale, LotRental, CommercialSpaceSale, CommercialSpaceRental, CommercialObjectSale, CommercialObjectRental, Investment

Status

Active, Cancelled, Closed, Pending, Draft

TaskStatus

Waiting, Solved, Cancelled

TaskType

Regular, Reminder, Appointment

ListingActivityEventType

Appointment, ContactAcquisition, Email, Printout

SeekerActivityEventType

Appointment, ContactAcquisition, Email

SeekerPrivilege

Contact, PublicContact, Edit, Related

ListingPrivilege

Contact, PublicContact, Edit, Related

ContractType

Exclusive, Open, None, Direct, CustomerApplication

OwnershipType

Mortgage, HousingCooperative, Shared, Other

Currency

PLN, EUR, USD

CustomerType

Person, Company

CustomerFrom

Press, Internet, Phone, DirectVisit, Command

CommissionPercentPeriod

Year, Month

ValueType

String, Integer, Float, Date, Boolean, Dictionary, DictionaryList

ScopeAll , Company,  Swo, Office
ConditionPerfect, VeryGood, Good, NeedsSmallRenovation, NeedsTotalRenovation, NeedsConversion, NeedsFinishing, OpenRawState, CloseRawState

Methods

  • Required paremeters are marked with *
  • If property is type of dictionary and both names are the same, name of dictionary is ommited f.ex. - sectionName(dictionary SectionName) -> sectionName(dictionary)
  • Methods that raturn that don't return no data except of success indicator are marked as succces/failure
  • No labels