Class: CcipDirectoryAndConfigurationRestApiV1::LanesApi
- Defined in:
- lib/ccip_directory_and_configuration_rest_api_v1/apis/lanes_api.rb
Overview
LanesApi
Constant Summary
Constants inherited from BaseApi
Instance Attribute Summary
Attributes inherited from BaseApi
Instance Method Summary collapse
-
#get_lanes(environment, source_chain_id: nil, destination_chain_id: nil, source_selector: nil, destination_selector: nil, source_internal_id: nil, destination_internal_id: nil, version: nil, output_key: OutputKey::CHAINID) ⇒ ApiResponse
Returns information about Cross-Chain Interoperability Protocol (CCIP) lanes between supported chains.
Methods inherited from BaseApi
#initialize, #new_parameter, #new_request_builder, #new_response_handler, user_agent, user_agent_parameters
Constructor Details
This class inherits a constructor from CcipDirectoryAndConfigurationRestApiV1::BaseApi
Instance Method Details
#get_lanes(environment, source_chain_id: nil, destination_chain_id: nil, source_selector: nil, destination_selector: nil, source_internal_id: nil, destination_internal_id: nil, version: nil, output_key: OutputKey::CHAINID) ⇒ ApiResponse
Returns information about Cross-Chain Interoperability Protocol (CCIP) lanes between supported chains. Each lane represents a unidirectional connection from a source chain to a destination chain, with associated onRamp and offRamp contracts and supported tokens. environment to query ID. Multiple chain IDs can be specified using comma-separated values destination chain ID. Multiple chain IDs can be specified using comma-separated values CCIP selector. Multiple selectors can be specified using comma-separated values destination chain CCIP selector. Multiple selectors can be specified using comma-separated values chain internal identifier. Multiple IDs can be specified using comma-separated values destination chain internal identifier. Multiple IDs can be specified using comma-separated values lanes where both onRamp and offRamp match the specified version will be returned organizing the lane keys in the response
38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 |
# File 'lib/ccip_directory_and_configuration_rest_api_v1/apis/lanes_api.rb', line 38 def get_lanes(environment, source_chain_id: nil, destination_chain_id: nil, source_selector: nil, destination_selector: nil, source_internal_id: nil, destination_internal_id: nil, version: nil, output_key: OutputKey::CHAINID) @api_call .request(new_request_builder(HttpMethodEnum::GET, '/lanes', Server::DEFAULT) .query_param(new_parameter(environment, key: 'environment') .is_required(true)) .query_param(new_parameter(source_chain_id, key: 'sourceChainId')) .query_param(new_parameter(destination_chain_id, key: 'destinationChainId')) .query_param(new_parameter(source_selector, key: 'sourceSelector')) .query_param(new_parameter(destination_selector, key: 'destinationSelector')) .query_param(new_parameter(source_internal_id, key: 'sourceInternalId')) .query_param(new_parameter(destination_internal_id, key: 'destinationInternalId')) .query_param(new_parameter(version, key: 'version')) .query_param(new_parameter(output_key, key: 'outputKey')) .header_param(new_parameter('application/json', key: 'accept'))) .response(new_response_handler .deserializer(APIHelper.method(:custom_type_deserializer)) .deserialize_into(LaneApiResponse.method(:from_hash)) .is_api_response(true) .local_error('400', 'Bad request - invalid parameters', ErrorResponseException) .local_error('500', 'Internal server error', ErrorResponseException)) .execute end |