Skip to main content

/3.0/ads/advise/gta/online

Advertising materials (3.0)

2GIS API Support: api@2gis.ru URL: https://docs.2gis.com/

Advertising

Getting GTA banners with enrichment

The request to advisor with the data enrichment. If the branch is not found in the database, it will be removed form the result. You get the enriched data not only via reference materials, but also via advertising materials in case the fallback scheme works (fake GTA-banner).

query Parameters
key
required
string

Unique key of API user.

Request Body schema: application/json

Query in json format.

One of
banner_slot
required
string
Enum: "recovery_list" "discovery_list"

The place of an advertising display.

query
required
string [ 1 .. 1024 ] characters

The text of the search query.

query_context_rubrics
Array of integers[ items ]

Contextual categories of the query grouped by equivalence.

region_id
integer

Project ID. Has the lowest priority among viewport and userLocation when defining the project.

auth_user_id
integer

The user ID from auth if a user is logged in.

object

The location of the user. Mandatory if available, and if not prohibited by GDPR.

locale
string = 5 characters

Locale.

product_id
integer

The product ID, the same as the one that is sent to BSS. If it is not passed, it will be taken from the key.

shv
string

Version of the shell. If the parameter has not been passed, the current version of the API will be taken.

Array of objects (PropPoint) = 4 items unique

Viewport coordinates. Can be used when a user is unknown, in order to understand what advertisers to offer them. The order of the points is strictly defined: counter-clockwise, starting from the top left corner.

user_id
string <uuid>

Obligatory, if not prohibited by GDPR. appInstanceId – for mobile apps, a regular BSS userID for other products.

Responses

Response Schema: application/json
required
object (ObjMeta)

Response metadata

required
object (PropGtaOnline)

Request samples

Content type
application/json
Example
{
  • "banner_slot": "recovery_list",
  • "query": "string",
  • "query_context_rubrics": [
    • [
      ]
    ],
  • "region_id": 0,
  • "auth_user_id": 0,
  • "user_location": {
    • "accuracy": 0,
    • "reliable": true,
    • "lon": 55.10401153,
    • "lat": 36.75896072
    },
  • "locale": "ru_RU",
  • "product_id": 0,
  • "shv": "string",
  • "viewport": [
    • {
      },
    • {
      },
    • {
      },
    • {
      }
    ],
  • "user_id": "a169451c-8525-4352-b8ca-070dd449a1a5"
}

Response samples

Content type
application/json
{
  • "meta": {
    • "code": 200,
    • "api_version": "dev",
    • "issue_date": "string"
    },
  • "result": {
    • "banners": [
      ],
    • "stories": {
      }
    }
}