ask_sdk_model.services.ups package

Submodules

Note

Canonical imports have been added in the __init__.py of the package. This helps in importing the class directly from the package, than through the module.

For eg: if package a has module b with class C, you can do from a import C instead of from a.b import C.

ask_sdk_model.services.ups.distance_units module

class ask_sdk_model.services.ups.distance_units.DistanceUnits

Bases: enum.Enum

Allowed enum values: [METRIC, IMPERIAL]

IMPERIAL = 'IMPERIAL'
METRIC = 'METRIC'
to_dict()

Returns the model properties as a dict

to_str()

Returns the string representation of the model

ask_sdk_model.services.ups.error module

class ask_sdk_model.services.ups.error.Error(code=None, message=None)

Bases: object

Parameters:
attribute_map = {'code': 'code', 'message': 'message'}
deserialized_types = {'code': 'ask_sdk_model.services.ups.error_code.ErrorCode', 'message': 'str'}
supports_multiple_types = False
to_dict()

Returns the model properties as a dict

to_str()

Returns the string representation of the model

ask_sdk_model.services.ups.error_code module

class ask_sdk_model.services.ups.error_code.ErrorCode

Bases: enum.Enum

A more precise error code. Some of these codes may not apply to some APIs. - INVALID_KEY: the setting key is not supported - INVALID_VALUE: the setting value is not valid - INVALID_TOKEN: the token is invalid - INVALID_URI: the uri is invalid - DEVICE_UNREACHABLE: the device is offline - UNKNOWN_ERROR: internal service error

Allowed enum values: [INVALID_KEY, INVALID_VALUE, INVALID_TOKEN, INVALID_URI, DEVICE_UNREACHABLE, UNKNOWN_ERROR]

DEVICE_UNREACHABLE = 'DEVICE_UNREACHABLE'
INVALID_KEY = 'INVALID_KEY'
INVALID_TOKEN = 'INVALID_TOKEN'
INVALID_URI = 'INVALID_URI'
INVALID_VALUE = 'INVALID_VALUE'
UNKNOWN_ERROR = 'UNKNOWN_ERROR'
to_dict()

Returns the model properties as a dict

to_str()

Returns the string representation of the model

ask_sdk_model.services.ups.phone_number module

class ask_sdk_model.services.ups.phone_number.PhoneNumber(country_code=None, phone_number=None)

Bases: object

Parameters:
  • country_code ((optional) str) –
  • phone_number ((optional) str) –
attribute_map = {'country_code': 'countryCode', 'phone_number': 'phoneNumber'}
deserialized_types = {'country_code': 'str', 'phone_number': 'str'}
supports_multiple_types = False
to_dict()

Returns the model properties as a dict

to_str()

Returns the string representation of the model

ask_sdk_model.services.ups.temperature_unit module

class ask_sdk_model.services.ups.temperature_unit.TemperatureUnit

Bases: enum.Enum

Allowed enum values: [CELSIUS, FAHRENHEIT]

CELSIUS = 'CELSIUS'
FAHRENHEIT = 'FAHRENHEIT'
to_dict()

Returns the model properties as a dict

to_str()

Returns the string representation of the model

ask_sdk_model.services.ups.ups_service_client module

class ask_sdk_model.services.ups.ups_service_client.UpsServiceClient(api_configuration, custom_user_agent=None)

Bases: ask_sdk_model.services.base_service_client.BaseServiceClient

ServiceClient for calling the UpsService APIs.

Parameters:api_configuration (ask_sdk_model.services.api_configuration.ApiConfiguration) – Instance of ApiConfiguration
get_profile_email(**kwargs)

Gets the email address of the customer associated with the current enablement. Requires customer consent for scopes: [alexa::profile:email:read]

Parameters:full_response (boolean) – Boolean value to check if response should contain headers and status code information. This value had to be passed through keyword arguments, by default the parameter value is set to False.
Return type:Union[ApiResponse, str, Error]
get_profile_given_name(**kwargs)

Gets the given name (first name) of the customer associated with the current enablement. Requires customer consent for scopes: [alexa::profile:given_name:read]

Parameters:full_response (boolean) – Boolean value to check if response should contain headers and status code information. This value had to be passed through keyword arguments, by default the parameter value is set to False.
Return type:Union[ApiResponse, str, Error]
get_profile_mobile_number(**kwargs)

Gets the mobile phone number of the customer associated with the current enablement. Requires customer consent for scopes: [alexa::profile:mobile_number:read]

Parameters:full_response (boolean) – Boolean value to check if response should contain headers and status code information. This value had to be passed through keyword arguments, by default the parameter value is set to False.
Return type:Union[ApiResponse, PhoneNumber, Error]
get_profile_name(**kwargs)

Gets the full name of the customer associated with the current enablement. Requires customer consent for scopes: [alexa::profile:name:read]

Parameters:full_response (boolean) – Boolean value to check if response should contain headers and status code information. This value had to be passed through keyword arguments, by default the parameter value is set to False.
Return type:Union[ApiResponse, str, Error]
get_system_distance_units(device_id, **kwargs)

Gets the distance measurement unit of the device. Does not require explict customer consent.

Parameters:
  • device_id (str) – (required) The device Id
  • full_response (boolean) – Boolean value to check if response should contain headers and status code information. This value had to be passed through keyword arguments, by default the parameter value is set to False.
Return type:

Union[ApiResponse, Error, DistanceUnits]

get_system_temperature_unit(device_id, **kwargs)

Gets the temperature measurement units of the device. Does not require explict customer consent.

Parameters:
  • device_id (str) – (required) The device Id
  • full_response (boolean) – Boolean value to check if response should contain headers and status code information. This value had to be passed through keyword arguments, by default the parameter value is set to False.
Return type:

Union[ApiResponse, TemperatureUnit, Error]

get_system_time_zone(device_id, **kwargs)

Gets the time zone of the device. Does not require explict customer consent.

Parameters:
  • device_id (str) – (required) The device Id
  • full_response (boolean) – Boolean value to check if response should contain headers and status code information. This value had to be passed through keyword arguments, by default the parameter value is set to False.
Return type:

Union[ApiResponse, str, Error]