renderaccountissues method
- RenderAccountIssuesRequestPayload request,
- String merchantId, {
- String? languageCode,
- String? timeZone,
- String? $fields,
Provide a list of merchant's issues with a support content and available actions.
This content and actions are meant to be rendered and shown in third-party applications.
request
- The metadata request object.
Request parameters:
merchantId
- Required. The ID of the account to fetch issues for.
languageCode
- Optional. The [IETF
BCP-47](https://tools.ietf.org/html/bcp47) language code used to localize
support content. If not set, the result will be in default language
en-US
.
timeZone
- Optional. The IANA
timezone used to localize times in support content. For example
'America/Los_Angeles'. If not set, results will use as a default UTC.
$fields
- Selector specifying which fields to include in a partial
response.
Completes with a RenderAccountIssuesResponse.
Completes with a commons.ApiRequestError if the API endpoint returned an error.
If the used http.Client
completes with an error when making a REST call,
this method will complete with the same error.
Implementation
async.Future<RenderAccountIssuesResponse> renderaccountissues(
RenderAccountIssuesRequestPayload request,
core.String merchantId, {
core.String? languageCode,
core.String? timeZone,
core.String? $fields,
}) async {
final body_ = convert.json.encode(request);
final queryParams_ = <core.String, core.List<core.String>>{
if (languageCode != null) 'languageCode': [languageCode],
if (timeZone != null) 'timeZone': [timeZone],
if ($fields != null) 'fields': [$fields],
};
final url_ = commons.escapeVariable('$merchantId') +
'/merchantsupport/renderaccountissues';
final response_ = await _requester.request(
url_,
'POST',
body: body_,
queryParams: queryParams_,
);
return RenderAccountIssuesResponse.fromJson(
response_ as core.Map<core.String, core.dynamic>);
}