Class: Verizon::M5gEdgePlatformsController
- Inherits:
-
BaseController
- Object
- BaseController
- Verizon::M5gEdgePlatformsController
- Defined in:
- lib/verizon/controllers/m_5g_edge_platforms_controller.rb
Overview
M5gEdgePlatformsController
Constant Summary
Constants inherited from BaseController
Instance Attribute Summary
Attributes inherited from BaseController
Instance Method Summary collapse
-
#list_mec_platforms(region: nil, service_profile_id: nil, subscriber_density: nil, ue_identity_type: nil, ue_identity: nil) ⇒ ApiResponse
Returns a list of optimal MEC Platforms where you can register your deployed application.
-
#list_regions ⇒ ApiResponse
List the geographical regions available, based on the user’s bearer token.
Methods inherited from BaseController
#initialize, #new_api_call_builder, #new_parameter, #new_request_builder, #new_response_handler, user_agent
Constructor Details
This class inherits a constructor from Verizon::BaseController
Instance Method Details
#list_mec_platforms(region: nil, service_profile_id: nil, subscriber_density: nil, ue_identity_type: nil, ue_identity: nil) ⇒ ApiResponse
Returns a list of optimal MEC Platforms where you can register your deployed application. Note: If a query is sent with all of the parameters, it will fail with a “400” error. You can search based on the following parameter combinations - region plus Service Profile ID and subscriber density (density is optional but recommended), region plus UEIdentity(Including UEIdentity Type) or Service Profile ID plus UEIdentity(Including UEIdentity Type). values are US_WEST_2 and US_EAST_1. of the service profile. 4G/5G subscribers per square kilometer. parameter: Type of User Equipment identifier used in ‘UEIdentity`. User Equipment. The type of identifier is defined by the ’UEIdentityType’ parameter. The`IPAddress`format can be IPv4 or IPv6.
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 |
# File 'lib/verizon/controllers/m_5g_edge_platforms_controller.rb', line 28 def list_mec_platforms(region: nil, service_profile_id: nil, subscriber_density: nil, ue_identity_type: nil, ue_identity: nil) new_api_call_builder .request(new_request_builder(HttpMethodEnum::GET, '/mecplatforms', Server::EDGE_DISCOVERY) .query_param(new_parameter(region, key: 'region')) .query_param(new_parameter(service_profile_id, key: 'serviceProfileId')) .query_param(new_parameter(subscriber_density, key: 'subscriberDensity')) .query_param(new_parameter(ue_identity_type, key: 'UEIdentityType')) .query_param(new_parameter(ue_identity, key: 'UEIdentity')) .header_param(new_parameter('application/json', key: 'accept')) .auth(And.new('thingspace_oauth', 'VZ-M2M-Token'))) .response(new_response_handler .deserializer(APIHelper.method(:custom_type_deserializer)) .deserialize_into(ListMECPlatformsResult.method(:from_hash)) .is_api_response(true) .local_error('400', 'HTTP 400 Bad Request.', EdgeDiscoveryResultException) .local_error('401', 'HTTP 401 Unauthorized.', EdgeDiscoveryResultException) .local_error('default', 'HTTP 500 Internal Server Error.', EdgeDiscoveryResultException)) .execute end |
#list_regions ⇒ ApiResponse
List the geographical regions available, based on the user’s bearer token. Note: Country code, Metropolitan area, Area and Zone are future functionality and will currently return a “null” value.
64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 |
# File 'lib/verizon/controllers/m_5g_edge_platforms_controller.rb', line 64 def list_regions new_api_call_builder .request(new_request_builder(HttpMethodEnum::GET, '/regions', Server::EDGE_DISCOVERY) .header_param(new_parameter('application/json', key: 'accept')) .auth(And.new('thingspace_oauth', 'VZ-M2M-Token'))) .response(new_response_handler .deserializer(APIHelper.method(:custom_type_deserializer)) .deserialize_into(ListRegionsResult.method(:from_hash)) .is_api_response(true) .local_error('400', 'HTTP 400 Bad Request.', EdgeDiscoveryResultException) .local_error('401', 'HTTP 401 Unauthorized.', EdgeDiscoveryResultException) .local_error('default', 'HTTP 500 Internal Server Error.', EdgeDiscoveryResultException)) .execute end |