bim93
bim93
requestPayment의 metadata 파라미터 사용방법 문의
async function requestPayment() {
// 공통 결제 데이터 객체를 생성합니다.
const paymentData = {
method: method, // 'CARD', 'VIRTUAL_ACCOUNT', 'TRANSFER' 중 하나
amount: {
currency: "KRW",
value: amount,
},
orderId: orderId,
orderName: orderName,
successUrl: window.location.origin + successUrl,
failUrl: window.location.origin + failUrl,
customerEmail: customerEmail,
customerName: customerName,
customerMobilePhone: customerMobilePhone,
metadata: {
product_type: product_type,
lecture_code: lecture_code,
},
};

// 결제 수단에 따라 추가 옵션을 설정합니다.
if (method === 'VIRTUAL_ACCOUNT') {
paymentData.virtualAccount = {
cashReceipt: {
type: "미발행",
},
validHours: 168,
};
} else if (method === 'TRANSFER') {
paymentData.transfer = {
cashReceipt: {
type: "미발행",
},
};
}

// 결제 요청을 수행합니다.
await payment.requestPayment(paymentData);
}

requestPayment().catch((r) => {
const btn_arr = []
btn_arr["confirm"] = {func: `location.href='${failUrl}';`};
custom_alert(r.message, "", btn_arr);
});
async function requestPayment() {
// 공통 결제 데이터 객체를 생성합니다.
const paymentData = {
method: method, // 'CARD', 'VIRTUAL_ACCOUNT', 'TRANSFER' 중 하나
amount: {
currency: "KRW",
value: amount,
},
orderId: orderId,
orderName: orderName,
successUrl: window.location.origin + successUrl,
failUrl: window.location.origin + failUrl,
customerEmail: customerEmail,
customerName: customerName,
customerMobilePhone: customerMobilePhone,
metadata: {
product_type: product_type,
lecture_code: lecture_code,
},
};

// 결제 수단에 따라 추가 옵션을 설정합니다.
if (method === 'VIRTUAL_ACCOUNT') {
paymentData.virtualAccount = {
cashReceipt: {
type: "미발행",
},
validHours: 168,
};
} else if (method === 'TRANSFER') {
paymentData.transfer = {
cashReceipt: {
type: "미발행",
},
};
}

// 결제 요청을 수행합니다.
await payment.requestPayment(paymentData);
}

requestPayment().catch((r) => {
const btn_arr = []
btn_arr["confirm"] = {func: `location.href='${failUrl}';`};
custom_alert(r.message, "", btn_arr);
});
metadata에 2개 추가해서 결제요청 성공하면 successUrl쪽에 파라미터로 보내주는거 아닌가요? 일단 추가해도 successUrl이동해도 파라미터로 안올길래 질문드립니다 어떻게 사용하는건가요? 예시를 알고싶습니다
7 replies
결제승인 API 파라미터 문의
https://docs.tosspayments.com/reference#request-body-%ED%8C%8C%EB%9D%BC%EB%AF%B8%ED%84%B0 필수 파라미터만 표시되어있는데 orderName도 넣을수 있는걸로 알고있어서요 orderName은 정확히 무엇인지 알고 싶고 그리고 또 다른 파라미터가 존재하나요 있다면 정보를 알고 싶습니다.
38 replies
[토스페이먼츠] TLS 1.2 미만 비보안채널 지원종료 안내 메일 문의
메일 내용은 대상 상점아이디(MID): pt_igunsul TLS1.0, TLS1.1 지원 종료 일자: 2024년 8월 1일 메일을 받았습니다 그래서 저희가 pt_igunsul 사용하는 전부 확인해봤는데 전부 TLS 1.2 적용되어있는 상태입니다 그리고 다름상점아이디들도 같은 서버에서 사용하는데 pt_igunsul 상점 아이디만 왜 특정 되었는지 궁금합니다 혹시 메일이 온 이유를 알 수 있을까요?
6 replies
자동결제 주문건 있는지 문의
혹시 7월 12일 아침 9시 2분경 특정 주문건 했는지 알 수 있을까요?
17 replies
flutter_inappwebview 6.0.0 으로 개발하고 있습니다
tosspayments_widget_sdk_flutter: ^1.0.1 사용할려고하는데
app\g_app> flutter pub add tosspayments_widget_sdk_flutter

Because tosspayments_widget_sdk_flutter >=1.0.0 depends on flutter_inappwebview ^5.0.0 and tosspayments_widget_sdk_flutter <1.0.0 depends on flutter_inappwebview ^5.8.0, every version of tosspayments_widget_sdk_flutter requires flutter_inappwebview ^5.0.0.
So, because g_app depends on both flutter_inappwebview ^6.0.0 and tosspayments_widget_sdk_flutter any, version solving failed.
app\g_app> flutter pub add tosspayments_widget_sdk_flutter

Because tosspayments_widget_sdk_flutter >=1.0.0 depends on flutter_inappwebview ^5.0.0 and tosspayments_widget_sdk_flutter <1.0.0 depends on flutter_inappwebview ^5.8.0, every version of tosspayments_widget_sdk_flutter requires flutter_inappwebview ^5.0.0.
So, because g_app depends on both flutter_inappwebview ^6.0.0 and tosspayments_widget_sdk_flutter any, version solving failed.
버전 호환때문에 설치가 안되네요 혹시 해결방법있을까요? 지금까지 6.0.0 기반으로 개발해서 다운그레이드하기에는 너무 먼길을 왔습니다 ㅠ
32 replies
파악이 잘 안되는 결제건을 확인하고 싶습니다
orderId에 housing1119이 들어간 요청건이 있었는지 확인하고 싶습니다
29 replies
가상계좌 입금하려니 개설기관 시스템 장애라고 뜨는데 왜 뜨는건가요?
가상계좌 입금하려니 개설기관 시스템 장애라고 뜨는데 왜 뜨는건가요?
21 replies
테스트 결제
No description
17 replies
상점관리자/개발자센터 상점이름이 안나옵니다
No description
7 replies
successUrl 로 이동시 추가적으로 파라미터를 보내고 싶습니다
쿼리스트링으로 보내면되는걸로 알고있는데 만약에 추가적으로 보내는 파라미터 양이 많다면 어떻게해야할까요?
12 replies
빌링결제 오류 문의. 빌링키 인증이 완료되지 않았거나 유효하지 않은 빌링 거래 건입니다.
저희 회원 한분이 예전에 빌링결제를 시도하셨는데 정지된카드로 하셨습니다. 이 카드로 다시 결제를 시도하면 빌링키를 못쓰는건가요?
18 replies
빌링결제시 카드번호를 다시 확인해주세요. 에러문의
빌링키 발급은 되는데 결제가 안되고 있습니다 https://api.tosspayments.com/v1/billing/빌링키
24 replies
가상계좌 결제신청할때 휴대폰번호를 적으면 successUrl에서 휴대폰 파라미터 어떻게 받나요
ㅈㄱㄴ
7 replies
환금성 제품 판매 MID 카드 테스트 결제시 문의
No description
27 replies
충전서비스 개발중 결제하기전 카드사 정보 문의
No description
24 replies
특정 결제건에 대해서 paymentKey 알 수 있을까요?
No description
11 replies
가상계좌 만료일시 문의
No description
23 replies
webhook 이벤트 추가 안내 메일을 받았습니다
No description
17 replies
신용.체크카 매출전표 문의
구모듈 http://pgweb.lgtelecom.com/WEB_SERVER/js/receipt_link.js showReceiptByTID 함수를 통해서 전표를 불러왔었습니다. receiptUrl말고 따로 전표를 불러오는 방법이 있을까요?
4 replies