- Navigation GuideYou are on a Command (operation) page with structural examples. Use the navigation breadcrumb if you would like to return to the Client landing page.
GetMapStyleDescriptorCommand
Retrieves the map style descriptor from a map resource.
The style descriptor contains specifications on how features render on a map. For example, what data to display, what order to display the data in, and the style for the data. Style descriptors follow the Mapbox Style Specification.
Example Syntax
Use a bare-bones client and the command you need to make an API call.
import { LocationClient, GetMapStyleDescriptorCommand } from "@aws-sdk/client-location"; // ES Modules import
// const { LocationClient, GetMapStyleDescriptorCommand } = require("@aws-sdk/client-location"); // CommonJS import
const client = new LocationClient(config);
const input = { // GetMapStyleDescriptorRequest
MapName: "STRING_VALUE", // required
Key: "STRING_VALUE",
};
const command = new GetMapStyleDescriptorCommand(input);
const response = await client.send(command);
// { // GetMapStyleDescriptorResponse
// Blob: new Uint8Array(),
// ContentType: "STRING_VALUE",
// CacheControl: "STRING_VALUE",
// };
GetMapStyleDescriptorCommand Input
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
MapName Required | string | undefined | The map resource to retrieve the style descriptor from. |
Key | string | undefined | The optional API key to authorize the request. |
GetMapStyleDescriptorCommand Output
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
$metadata Required | ResponseMetadata | Metadata pertaining to this request. |
Throws
Name | Fault | Details |
---|
Name | Fault | Details |
---|---|---|
AccessDeniedException | client | The request was denied because of insufficient access or permissions. Check with an administrator to verify your permissions. |
InternalServerException | server | The request has failed to process because of an unknown server error, exception, or failure. |
ResourceNotFoundException | client | The resource that you've entered was not found in your AWS account. |
ThrottlingException | client | The request was denied because of request throttling. |
ValidationException | client | The input failed to meet the constraints specified by the AWS service. |
LocationServiceException | Base exception class for all service exceptions from Location service. |