주문 결제링크 리다이렉트
curl --request GET \
--url https://api.steppay.kr/api/v1/orders/{idOrCode}/pay \
--header 'Secret-Token: <api-key>'import requests
url = "https://api.steppay.kr/api/v1/orders/{idOrCode}/pay"
headers = {"Secret-Token": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'Secret-Token': '<api-key>'}};
fetch('https://api.steppay.kr/api/v1/orders/{idOrCode}/pay', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.steppay.kr/api/v1/orders/{idOrCode}/pay",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Secret-Token: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.steppay.kr/api/v1/orders/{idOrCode}/pay"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Secret-Token", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.steppay.kr/api/v1/orders/{idOrCode}/pay")
.header("Secret-Token", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.steppay.kr/api/v1/orders/{idOrCode}/pay")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Secret-Token"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"applicationContext": {
"displayName": "<string>",
"autowireCapableBeanFactory": {},
"applicationName": "<string>",
"startupDate": 123,
"parent": "<unknown>",
"id": "<string>",
"environment": {
"activeProfiles": [
"<string>"
],
"defaultProfiles": [
"<string>"
]
},
"beanDefinitionCount": 123,
"beanDefinitionNames": [
"<string>"
],
"parentBeanFactory": {},
"classLoader": {
"parent": {
"name": "<string>",
"unnamedModule": {
"layer": {},
"name": "<string>",
"descriptor": {
"open": true,
"automatic": true
},
"classLoader": {
"name": "<string>",
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
},
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"named": true,
"packages": [
"<string>"
]
},
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
},
"name": "<string>",
"unnamedModule": {
"layer": {},
"name": "<string>",
"descriptor": {
"open": true,
"automatic": true
},
"classLoader": {
"name": "<string>",
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
},
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"named": true,
"packages": [
"<string>"
]
},
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
}
},
"contentType": "<string>",
"requestContextAttribute": "<string>",
"staticAttributes": {},
"exposePathVariables": true,
"beanName": "<string>",
"url": "<string>",
"hosts": [
"<string>"
],
"propagateQueryProperties": true,
"redirectView": true,
"attributesMap": {}
}{
"errorCode": "<string>",
"traceId": "<string>",
"errorMessage": "<string>",
"details": {}
}{
"errorCode": "<string>",
"traceId": "<string>",
"errorMessage": "<string>",
"details": {}
}{
"applicationContext": {
"displayName": "<string>",
"autowireCapableBeanFactory": {},
"applicationName": "<string>",
"startupDate": 123,
"parent": "<unknown>",
"id": "<string>",
"environment": {
"activeProfiles": [
"<string>"
],
"defaultProfiles": [
"<string>"
]
},
"beanDefinitionCount": 123,
"beanDefinitionNames": [
"<string>"
],
"parentBeanFactory": {},
"classLoader": {
"parent": {
"name": "<string>",
"unnamedModule": {
"layer": {},
"name": "<string>",
"descriptor": {
"open": true,
"automatic": true
},
"classLoader": {
"name": "<string>",
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
},
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"named": true,
"packages": [
"<string>"
]
},
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
},
"name": "<string>",
"unnamedModule": {
"layer": {},
"name": "<string>",
"descriptor": {
"open": true,
"automatic": true
},
"classLoader": {
"name": "<string>",
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
},
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"named": true,
"packages": [
"<string>"
]
},
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
}
},
"contentType": "<string>",
"requestContextAttribute": "<string>",
"staticAttributes": {},
"exposePathVariables": true,
"beanName": "<string>",
"url": "<string>",
"hosts": [
"<string>"
],
"propagateQueryProperties": true,
"redirectView": true,
"attributesMap": {}
}주문 API
주문 결제링크 리다이렉트
직접 제어 하고 싶은 경우 응답에 포함된 Location 헤더를 확인하여 리다이렉트될 URI을 가져와 처리하시면 됩니다. 우측의 API 테스트 툴에서는 302 리다이렉트가 제대로 표현되지 않습니다.
GET
/
api
/
v1
/
orders
/
{idOrCode}
/
pay
주문 결제링크 리다이렉트
curl --request GET \
--url https://api.steppay.kr/api/v1/orders/{idOrCode}/pay \
--header 'Secret-Token: <api-key>'import requests
url = "https://api.steppay.kr/api/v1/orders/{idOrCode}/pay"
headers = {"Secret-Token": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'Secret-Token': '<api-key>'}};
fetch('https://api.steppay.kr/api/v1/orders/{idOrCode}/pay', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.steppay.kr/api/v1/orders/{idOrCode}/pay",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Secret-Token: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.steppay.kr/api/v1/orders/{idOrCode}/pay"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Secret-Token", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.steppay.kr/api/v1/orders/{idOrCode}/pay")
.header("Secret-Token", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.steppay.kr/api/v1/orders/{idOrCode}/pay")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Secret-Token"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"applicationContext": {
"displayName": "<string>",
"autowireCapableBeanFactory": {},
"applicationName": "<string>",
"startupDate": 123,
"parent": "<unknown>",
"id": "<string>",
"environment": {
"activeProfiles": [
"<string>"
],
"defaultProfiles": [
"<string>"
]
},
"beanDefinitionCount": 123,
"beanDefinitionNames": [
"<string>"
],
"parentBeanFactory": {},
"classLoader": {
"parent": {
"name": "<string>",
"unnamedModule": {
"layer": {},
"name": "<string>",
"descriptor": {
"open": true,
"automatic": true
},
"classLoader": {
"name": "<string>",
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
},
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"named": true,
"packages": [
"<string>"
]
},
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
},
"name": "<string>",
"unnamedModule": {
"layer": {},
"name": "<string>",
"descriptor": {
"open": true,
"automatic": true
},
"classLoader": {
"name": "<string>",
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
},
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"named": true,
"packages": [
"<string>"
]
},
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
}
},
"contentType": "<string>",
"requestContextAttribute": "<string>",
"staticAttributes": {},
"exposePathVariables": true,
"beanName": "<string>",
"url": "<string>",
"hosts": [
"<string>"
],
"propagateQueryProperties": true,
"redirectView": true,
"attributesMap": {}
}{
"errorCode": "<string>",
"traceId": "<string>",
"errorMessage": "<string>",
"details": {}
}{
"errorCode": "<string>",
"traceId": "<string>",
"errorMessage": "<string>",
"details": {}
}{
"applicationContext": {
"displayName": "<string>",
"autowireCapableBeanFactory": {},
"applicationName": "<string>",
"startupDate": 123,
"parent": "<unknown>",
"id": "<string>",
"environment": {
"activeProfiles": [
"<string>"
],
"defaultProfiles": [
"<string>"
]
},
"beanDefinitionCount": 123,
"beanDefinitionNames": [
"<string>"
],
"parentBeanFactory": {},
"classLoader": {
"parent": {
"name": "<string>",
"unnamedModule": {
"layer": {},
"name": "<string>",
"descriptor": {
"open": true,
"automatic": true
},
"classLoader": {
"name": "<string>",
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
},
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"named": true,
"packages": [
"<string>"
]
},
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
},
"name": "<string>",
"unnamedModule": {
"layer": {},
"name": "<string>",
"descriptor": {
"open": true,
"automatic": true
},
"classLoader": {
"name": "<string>",
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
},
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"named": true,
"packages": [
"<string>"
]
},
"registeredAsParallelCapable": true,
"definedPackages": [
{
"name": "<string>",
"specificationTitle": "<string>",
"specificationVersion": "<string>",
"specificationVendor": "<string>",
"implementationTitle": "<string>",
"implementationVersion": "<string>",
"implementationVendor": "<string>",
"annotations": [
{}
],
"declaredAnnotations": [
{}
],
"sealed": true
}
]
}
},
"contentType": "<string>",
"requestContextAttribute": "<string>",
"staticAttributes": {},
"exposePathVariables": true,
"beanName": "<string>",
"url": "<string>",
"hosts": [
"<string>"
],
"propagateQueryProperties": true,
"redirectView": true,
"attributesMap": {}
}Authorizations
Path Parameters
주문 번호 또는 코드(주문 번호는 deprecate 될 예정입니다)
Query Parameters
결제 성공시 리다이렉트 될 URL
결제 실패시 리다이렉트 될 URL
결제 취소시 리다이렉트 될 URL
Response
결제링크로 리다이렉트 됩니다.
⌘I