# Get Processor Route GET https://app.paymentkit.com/api/{account_id}/processor-routes/{route_id} Get a single processor route by ID. Reference: https://docs.paymentkit.com/api-reference/api-reference/processor-routes/get-processor-route ## OpenAPI Specification ```yaml openapi: 3.1.0 info: title: Core API version: 1.0.0 paths: /api/{account_id}/processor-routes/{route_id}: get: operationId: get-processor-route summary: Get Processor Route description: Get a single processor route by ID. tags: - subpackage_processorRoutes parameters: - name: route_id in: path required: true schema: type: string - name: account_id in: path required: true schema: type: string - name: Authorization in: header description: Bearer authentication required: true schema: type: string responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/ProcessorRoute' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' servers: - url: https://app.paymentkit.com - url: https://staging.paymentkit.com components: schemas: RouteProcessor: type: object properties: processor_id: type: string description: Processor ID required: - processor_id description: A processor entry in a route. title: RouteProcessor ProcessorRoute: type: object properties: id: type: string description: Unique route identifier name: type: string description: Route name description: type: - string - 'null' description: Route description processors: type: array items: $ref: '#/components/schemas/RouteProcessor' description: Ordered list of processors created_at: type: string format: date-time description: When the route was created updated_at: type: string format: date-time description: When the route was last updated required: - id - name - processors - created_at - updated_at description: Schema for processor route response. title: ProcessorRoute ValidationErrorLocItems: oneOf: - type: string - type: integer title: ValidationErrorLocItems ValidationError: type: object properties: loc: type: array items: $ref: '#/components/schemas/ValidationErrorLocItems' msg: type: string type: type: string required: - loc - msg - type title: ValidationError HTTPValidationError: type: object properties: detail: type: array items: $ref: '#/components/schemas/ValidationError' title: HTTPValidationError securitySchemes: HTTPBearer: type: http scheme: bearer ``` ## SDK Code Examples ```python from payment_kit import PaymentKit client = PaymentKit( token="YOUR_TOKEN_HERE", ) client.processor_routes.get_processor_route( route_id="route_id", account_id="account_id", ) ``` ```javascript const url = 'https://app.paymentkit.com/api/account_id/processor-routes/route_id'; const options = { method: 'GET', headers: {Authorization: 'Bearer ', 'Content-Type': 'application/json'}, body: '{}' }; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://app.paymentkit.com/api/account_id/processor-routes/route_id" payload := strings.NewReader("{}") req, _ := http.NewRequest("GET", url, payload) req.Header.Add("Authorization", "Bearer ") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://app.paymentkit.com/api/account_id/processor-routes/route_id") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["Authorization"] = 'Bearer ' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://app.paymentkit.com/api/account_id/processor-routes/route_id") .header("Authorization", "Bearer ") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php request('GET', 'https://app.paymentkit.com/api/account_id/processor-routes/route_id', [ 'body' => '{}', 'headers' => [ 'Authorization' => 'Bearer ', 'Content-Type' => 'application/json', ], ]); echo $response->getBody(); ``` ```csharp using RestSharp; var client = new RestClient("https://app.paymentkit.com/api/account_id/processor-routes/route_id"); var request = new RestRequest(Method.GET); request.AddHeader("Authorization", "Bearer "); request.AddHeader("Content-Type", "application/json"); request.AddParameter("application/json", "{}", ParameterType.RequestBody); IRestResponse response = client.Execute(request); ``` ```swift import Foundation let headers = [ "Authorization": "Bearer ", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://app.paymentkit.com/api/account_id/processor-routes/route_id")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ```