update
Changes the advertiser parameters and the user settings for the advertiser's representative.
Any representative of an advertiser can edit the advertiser's parameters and their own personal settings.
The advertiser's chief representative can also edit the settings of another representative. To do this, pass the representative's username in the Client-Login request header.
Request
The ClientInfo, Notification, and Phone parameters belong to the user who is a representative of the advertiser:
- The user the request is made on behalf of, if the request is in the name of any representative of the advertiser and the HTTP Client-Login header is not included in the request.
- The user whose username is specified in the HTTP Client-Login header, if the request is in the name of the advertiser's chief representative and the request includes the HTTP Client-Login header.
The Settings parameter is related to the advertiser, regardless of who the representative is.
Request structure in JSON format:
{
"method": "update",
"params": { /* params */
"Clients": [{ /* ClientUpdateItem */
"ClientInfo": (string),
"Notification": { /* NotificationUpdate */
"Lang": ( "RU" | "UK" | "EN" | "TR" ),
"Email": (string),
"EmailSubscriptions": [{ /* EmailSubscriptionItem */
"Option": ( "RECEIVE_RECOMMENDATIONS" | "TRACK_MANAGED_CAMPAIGNS" | "TRACK_POSITION_CHANGES" ), /* required */
"Value": ( "YES" | "NO" ) /* required */
}, ... ]
},
"Phone": (string),
"Settings": [{ /* ClientSettingUpdateItem */
"Option": ( "CORRECT_TYPOS_AUTOMATICALLY" | "DISPLAY_STORE_RATING" ), /* required */
"Value": ( "YES" | "NO" ) /* required */
}, ... ],
"TinInfo" : { /* TinInfoUpdate */
"TinType" : ( "PHYSICAL" | "FOREIGN_PHYSICAL" | "LEGAL" | "FOREIGN_LEGAL" | "INDIVIDUAL" ),
"Tin" : (string) /* nillable */
}, /* nillable */
"ErirAttributes": { /* ErirAttributesUpdate */
"Organization": { /* OrganizationUpdate */
"Name": (string), /* nillable */
"EpayNumber": (string), /* nillable */
"RegNumber": (string), /* nillable */
"OksmNumber": (string), /* nillable */
"OkvedCode": (string) /* nillable */
}, /* nillable */
"Contract": { /* ContractUpdate */
"Number": (string), /* nillable */
"Date": (string), /* nillable */
"Type": ( "CONTRACT" | "INTERMEDIARY_CONTRACT" | "ADDITIONAL_AGREEMENT" ), /* nillable */
"ActionType": ( "COMMERCIAL" | "DISTRIBUTION" | "CONCLUDE" | "OTHER" ), /* nillable */
"SubjectType": ( "REPRESENTATION" | "MEDIATION" | "DISTRIBUTION" | "ORG_DISTRIBUTION" | "OTHER" ), /* nillable */
"Price": { /* PriceUpdate */
"Amount": (decimal), /* required */
"IncludingVat": ( "YES" | "NO" ) /* required */
} /* nillable */
}, /* nillable */
"Contragent": { /* ContragentUpdate */
"Name": (string), /* nillable */
"Phone": (string), /* nillable */
"EpayNumber": (string), /* nillable */
"RegNumber": (string), /* nillable */
"OksmNumber": (string), /* nillable */
"TinInfo": { /* TinInfoUpdate */
"TinType": ( "PHYSICAL" | "FOREIGN_PHYSICAL" | "LEGAL" | "FOREIGN_LEGAL" | "INDIVIDUAL" ),
"Tin": (string) /* nillable */
} /* nillable */
} /* nillable */
} /* nillable */
}] /* required */
}
}
Parameter | Type | Description | Required |
Params structure (for JSON) / UpdateRequest structure (for SOAP) | |||
---|---|---|---|
Clients | array of ClientUpdateItem | Advertiser parameters and user settings to change. | Yes |
ClientUpdateItem structure | |||
ClientInfo | string | First and last name of the Yandex Direct user (no more than 255 characters). | No |
Notification | NotificationUpdate | The Yandex Direct user's settings for SMS and email notifications. | No |
Phone | string | Phone number of the Yandex Direct user (255 characters maximum). | No |
Settings | array of ClientSettingUpdateItem | Advertiser settings that only allow YES or NO values. | No |
TinInfo | TinInfoUpdate | Tax data of the end-advertiser. | No |
ErirAttributes | ErirAttributesUpdate | Additional advertiser data to label ads with. | No |
NotificationUpdate structure | |||
Lang | LangEnum | Language for notifications. | No |
Email | string | The email address for sending notifications related to the account (no more than 255 characters). | No |
EmailSubscriptions | array of EmailSubscriptionItem | Types of notifications to send by email. | No |
EmailSubscriptionItem structure | |||
Option | EmailSubscriptionEnum | Type of notification:
| Yes |
Value | YesNoEnum | Whether to send this type of notification. | Yes |
ClientSettingUpdateItem structure | |||
Option | ClientSettingUpdateEnum | Setting name:
| Yes |
Value | YesNoEnum | Setting value. | Yes |
TinInfoUpdate structure | |||
TinType | TinTypeEnum | Organization type:
| No |
Tin | string | The taxpayer number or its equivalent in the country of registration. | No |
ErirAttributesUpdate structure | |||
Organization | OrganizationUpdate | Details about the organization of the end-advertiser. | No |
Contract | ContractUpdate | Details of the contract of the client counterparty with the end-advertiser. | No |
Contragent | ContragentUpdate | Information about the counterparty of the end-advertiser. | No |
OrganizationUpdate structure | |||
Name | string | Organization name. | No |
EpayNumber | string | The number of the electronic payment instrument. | No |
RegNumber | string | Registration number or its equivalent. | No |
OksmNumber | string | Legal entity's code of the country of registration according to OKSM. | No |
OkvedCode | string | Business category code according to OKVED. | No |
ContractUpdate structure | |||
Number | string | Contract number. | No |
Date | string | Contract date in the format YYYY-MM-DD. | No |
Type | ContractTypeEnum | Type of contract:
| No |
ActionType | ContractActionTypeEnum | Types of activities of the intermediary representative:
| No |
SubjectType | ContractSubjectTypeEnum | Contract subject:
| No |
Price | ContractPrice | The value of the contract. | No |
ContractPrice structure | |||
Amount | decimal | The value of the contract. | Yes |
IncludingVat | YesNoEnum | Whether VAT is included in the contract value. | Yes |
ContragentUpdate structure | |||
Name | string | Name. | No |
Phone | string | Phone number. | No |
EpayNumber | string | The number of the electronic payment instrument. | No |
RegNumber | string | Registration number or its equivalent. | No |
OksmNumber | string | Legal entity's code of the country of registration according to OKSM. | No |
TinInfo | TinInfoUpdate | Tax details of the counterparty. | No |
Parameter | Type | Description | Required |
Params structure (for JSON) / UpdateRequest structure (for SOAP) | |||
---|---|---|---|
Clients | array of ClientUpdateItem | Advertiser parameters and user settings to change. | Yes |
ClientUpdateItem structure | |||
ClientInfo | string | First and last name of the Yandex Direct user (no more than 255 characters). | No |
Notification | NotificationUpdate | The Yandex Direct user's settings for SMS and email notifications. | No |
Phone | string | Phone number of the Yandex Direct user (255 characters maximum). | No |
Settings | array of ClientSettingUpdateItem | Advertiser settings that only allow YES or NO values. | No |
TinInfo | TinInfoUpdate | Tax data of the end-advertiser. | No |
ErirAttributes | ErirAttributesUpdate | Additional advertiser data to label ads with. | No |
NotificationUpdate structure | |||
Lang | LangEnum | Language for notifications. | No |
Email | string | The email address for sending notifications related to the account (no more than 255 characters). | No |
EmailSubscriptions | array of EmailSubscriptionItem | Types of notifications to send by email. | No |
EmailSubscriptionItem structure | |||
Option | EmailSubscriptionEnum | Type of notification:
| Yes |
Value | YesNoEnum | Whether to send this type of notification. | Yes |
ClientSettingUpdateItem structure | |||
Option | ClientSettingUpdateEnum | Setting name:
| Yes |
Value | YesNoEnum | Setting value. | Yes |
TinInfoUpdate structure | |||
TinType | TinTypeEnum | Organization type:
| No |
Tin | string | The taxpayer number or its equivalent in the country of registration. | No |
ErirAttributesUpdate structure | |||
Organization | OrganizationUpdate | Details about the organization of the end-advertiser. | No |
Contract | ContractUpdate | Details of the contract of the client counterparty with the end-advertiser. | No |
Contragent | ContragentUpdate | Information about the counterparty of the end-advertiser. | No |
OrganizationUpdate structure | |||
Name | string | Organization name. | No |
EpayNumber | string | The number of the electronic payment instrument. | No |
RegNumber | string | Registration number or its equivalent. | No |
OksmNumber | string | Legal entity's code of the country of registration according to OKSM. | No |
OkvedCode | string | Business category code according to OKVED. | No |
ContractUpdate structure | |||
Number | string | Contract number. | No |
Date | string | Contract date in the format YYYY-MM-DD. | No |
Type | ContractTypeEnum | Type of contract:
| No |
ActionType | ContractActionTypeEnum | Types of activities of the intermediary representative:
| No |
SubjectType | ContractSubjectTypeEnum | Contract subject:
| No |
Price | ContractPrice | The value of the contract. | No |
ContractPrice structure | |||
Amount | decimal | The value of the contract. | Yes |
IncludingVat | YesNoEnum | Whether VAT is included in the contract value. | Yes |
ContragentUpdate structure | |||
Name | string | Name. | No |
Phone | string | Phone number. | No |
EpayNumber | string | The number of the electronic payment instrument. | No |
RegNumber | string | Registration number or its equivalent. | No |
OksmNumber | string | Legal entity's code of the country of registration according to OKSM. | No |
TinInfo | TinInfoUpdate | Tax details of the counterparty. | No |
Response
Response structure in JSON format:
{
"result": { /* result */
"UpdateResults": [{ /* ClientsActionResult */
"ClientId": (long),
"Warnings": [{ /* ExceptionNotification */
"Code": (int), /* required */
"Message": (string), /* required */
"Details": (string)
}, ...
],
"Errors": [{ /* ExceptionNotification */
"Code": (int), /* required */
"Message": (string), /* required */
"Details": (string)
}, ...
]
}, ... ] /* required */
}
}
Parameter | Type | Description |
Result structure (for JSON) / UpdateResponse structure (for SOAP) | ||
---|---|---|
UpdateResults | array of ClientsActionResult | The result of changing advertiser parameters and user settings. |
ClientsActionResult structure | ||
ClientId | long | Advertiser ID. Returned if there are no errors, see Operations on object arrays. |
Warnings | array of ExceptionNotification | Warnings that occurred during the operation. |
Errors | array of ExceptionNotification | Errors that occurred during the operation. |
Parameter | Type | Description |
Result structure (for JSON) / UpdateResponse structure (for SOAP) | ||
---|---|---|
UpdateResults | array of ClientsActionResult | The result of changing advertiser parameters and user settings. |
ClientsActionResult structure | ||
ClientId | long | Advertiser ID. Returned if there are no errors, see Operations on object arrays. |
Warnings | array of ExceptionNotification | Warnings that occurred during the operation. |
Errors | array of ExceptionNotification | Errors that occurred during the operation. |