[{"data":1,"prerenderedAt":403},["ShallowReactive",2],{"doc-\u002Fdocs\u002Fget-session":3,"docs-nav":359,"docs-order":391},{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":8,"description":9,"body":10,"_type":353,"_id":354,"_source":355,"_file":356,"_stem":357,"_extension":358},"\u002Fdocs\u002Fget-session","docs",false,"","Get Session","Fetches the current state of a checkout session.",{"type":11,"children":12,"toc":349},"root",[13,22,27,33,37,51,58,140,146,159,313,334,343],{"type":14,"tag":15,"props":16,"children":18},"element","h1",{"id":17},"get-a-session",[19],{"type":20,"value":21},"text","Get a session",{"type":14,"tag":23,"props":24,"children":25},"p",{},[26],{"type":20,"value":9},{"type":14,"tag":28,"props":29,"children":32},"endpoint-meta",{"method":30,"path":31},"GET","\u002Fv1\u002Fsession\u002F{session_id}",[],{"type":14,"tag":34,"props":35,"children":36},"env-toggle",{},[],{"type":14,"tag":23,"props":38,"children":39},{},[40,42,49],{"type":20,"value":41},"Send the signed headers only (signing string ",{"type":14,"tag":43,"props":44,"children":46},"code",{"className":45},[],[47],{"type":20,"value":48},"merchant_code|timestamp",{"type":20,"value":50},").",{"type":14,"tag":52,"props":53,"children":55},"h2",{"id":54},"example-request",[56],{"type":20,"value":57},"Example request",{"type":14,"tag":59,"props":60,"children":64},"pre",{"className":61,"code":62,"language":63,"meta":7,"style":7},"language-bash shiki shiki-themes github-dark","curl https:\u002F\u002Fpay.syok2pay-sandbox.com\u002Fv1\u002Fsession\u002Fcs_abc123 \\\n  -H \"Authorization: Bearer pk_...\" \\\n  -H \"X-Timestamp: 1714280400\" \\\n  -H \"X-Signature: \u003Chmac>\"\n","bash",[65],{"type":14,"tag":43,"props":66,"children":67},{"__ignoreMap":7},[68,92,110,127],{"type":14,"tag":69,"props":70,"children":73},"span",{"class":71,"line":72},"line",1,[74,80,86],{"type":14,"tag":69,"props":75,"children":77},{"style":76},"--shiki-default:#B392F0",[78],{"type":20,"value":79},"curl",{"type":14,"tag":69,"props":81,"children":83},{"style":82},"--shiki-default:#9ECBFF",[84],{"type":20,"value":85}," https:\u002F\u002Fpay.syok2pay-sandbox.com\u002Fv1\u002Fsession\u002Fcs_abc123",{"type":14,"tag":69,"props":87,"children":89},{"style":88},"--shiki-default:#79B8FF",[90],{"type":20,"value":91}," \\\n",{"type":14,"tag":69,"props":93,"children":95},{"class":71,"line":94},2,[96,101,106],{"type":14,"tag":69,"props":97,"children":98},{"style":88},[99],{"type":20,"value":100},"  -H",{"type":14,"tag":69,"props":102,"children":103},{"style":82},[104],{"type":20,"value":105}," \"Authorization: Bearer pk_...\"",{"type":14,"tag":69,"props":107,"children":108},{"style":88},[109],{"type":20,"value":91},{"type":14,"tag":69,"props":111,"children":113},{"class":71,"line":112},3,[114,118,123],{"type":14,"tag":69,"props":115,"children":116},{"style":88},[117],{"type":20,"value":100},{"type":14,"tag":69,"props":119,"children":120},{"style":82},[121],{"type":20,"value":122}," \"X-Timestamp: 1714280400\"",{"type":14,"tag":69,"props":124,"children":125},{"style":88},[126],{"type":20,"value":91},{"type":14,"tag":69,"props":128,"children":130},{"class":71,"line":129},4,[131,135],{"type":14,"tag":69,"props":132,"children":133},{"style":88},[134],{"type":20,"value":100},{"type":14,"tag":69,"props":136,"children":137},{"style":82},[138],{"type":20,"value":139}," \"X-Signature: \u003Chmac>\"\n",{"type":14,"tag":52,"props":141,"children":143},{"id":142},"example-response",[144],{"type":20,"value":145},"Example response",{"type":14,"tag":23,"props":147,"children":148},{},[149,151,157],{"type":20,"value":150},"The gateway passes the processor's session payload through unchanged (a flat\nobject keyed by ",{"type":14,"tag":43,"props":152,"children":154},{"className":153},[],[155],{"type":20,"value":156},"status_code",{"type":20,"value":158},"). On success:",{"type":14,"tag":59,"props":160,"children":164},{"className":161,"code":162,"language":163,"meta":7,"style":7},"language-json shiki shiki-themes github-dark","{\n  \"status_code\": \"SUCCESS\",\n  \"session_id\": \"cs_abc123\",\n  \"status\": \"PENDING\",\n  \"amount\": \"3.00\",\n  \"currency\": \"MYR\",\n  \"reference_no\": \"ORD-20260428-003\"\n}\n","json",[165],{"type":14,"tag":43,"props":166,"children":167},{"__ignoreMap":7},[168,177,200,221,242,264,286,304],{"type":14,"tag":69,"props":169,"children":170},{"class":71,"line":72},[171],{"type":14,"tag":69,"props":172,"children":174},{"style":173},"--shiki-default:#E1E4E8",[175],{"type":20,"value":176},"{\n",{"type":14,"tag":69,"props":178,"children":179},{"class":71,"line":94},[180,185,190,195],{"type":14,"tag":69,"props":181,"children":182},{"style":88},[183],{"type":20,"value":184},"  \"status_code\"",{"type":14,"tag":69,"props":186,"children":187},{"style":173},[188],{"type":20,"value":189},": ",{"type":14,"tag":69,"props":191,"children":192},{"style":82},[193],{"type":20,"value":194},"\"SUCCESS\"",{"type":14,"tag":69,"props":196,"children":197},{"style":173},[198],{"type":20,"value":199},",\n",{"type":14,"tag":69,"props":201,"children":202},{"class":71,"line":112},[203,208,212,217],{"type":14,"tag":69,"props":204,"children":205},{"style":88},[206],{"type":20,"value":207},"  \"session_id\"",{"type":14,"tag":69,"props":209,"children":210},{"style":173},[211],{"type":20,"value":189},{"type":14,"tag":69,"props":213,"children":214},{"style":82},[215],{"type":20,"value":216},"\"cs_abc123\"",{"type":14,"tag":69,"props":218,"children":219},{"style":173},[220],{"type":20,"value":199},{"type":14,"tag":69,"props":222,"children":223},{"class":71,"line":129},[224,229,233,238],{"type":14,"tag":69,"props":225,"children":226},{"style":88},[227],{"type":20,"value":228},"  \"status\"",{"type":14,"tag":69,"props":230,"children":231},{"style":173},[232],{"type":20,"value":189},{"type":14,"tag":69,"props":234,"children":235},{"style":82},[236],{"type":20,"value":237},"\"PENDING\"",{"type":14,"tag":69,"props":239,"children":240},{"style":173},[241],{"type":20,"value":199},{"type":14,"tag":69,"props":243,"children":245},{"class":71,"line":244},5,[246,251,255,260],{"type":14,"tag":69,"props":247,"children":248},{"style":88},[249],{"type":20,"value":250},"  \"amount\"",{"type":14,"tag":69,"props":252,"children":253},{"style":173},[254],{"type":20,"value":189},{"type":14,"tag":69,"props":256,"children":257},{"style":82},[258],{"type":20,"value":259},"\"3.00\"",{"type":14,"tag":69,"props":261,"children":262},{"style":173},[263],{"type":20,"value":199},{"type":14,"tag":69,"props":265,"children":267},{"class":71,"line":266},6,[268,273,277,282],{"type":14,"tag":69,"props":269,"children":270},{"style":88},[271],{"type":20,"value":272},"  \"currency\"",{"type":14,"tag":69,"props":274,"children":275},{"style":173},[276],{"type":20,"value":189},{"type":14,"tag":69,"props":278,"children":279},{"style":82},[280],{"type":20,"value":281},"\"MYR\"",{"type":14,"tag":69,"props":283,"children":284},{"style":173},[285],{"type":20,"value":199},{"type":14,"tag":69,"props":287,"children":289},{"class":71,"line":288},7,[290,295,299],{"type":14,"tag":69,"props":291,"children":292},{"style":88},[293],{"type":20,"value":294},"  \"reference_no\"",{"type":14,"tag":69,"props":296,"children":297},{"style":173},[298],{"type":20,"value":189},{"type":14,"tag":69,"props":300,"children":301},{"style":82},[302],{"type":20,"value":303},"\"ORD-20260428-003\"\n",{"type":14,"tag":69,"props":305,"children":307},{"class":71,"line":306},8,[308],{"type":14,"tag":69,"props":309,"children":310},{"style":173},[311],{"type":20,"value":312},"}\n",{"type":14,"tag":23,"props":314,"children":315},{},[316,318,324,326,332],{"type":20,"value":317},"A missing session returns ",{"type":14,"tag":43,"props":319,"children":321},{"className":320},[],[322],{"type":20,"value":323},"404",{"type":20,"value":325}," with ",{"type":14,"tag":43,"props":327,"children":329},{"className":328},[],[330],{"type":20,"value":331},"{ \"status_code\": \"SESSION_NOT_FOUND\", \"status_description\": \"...\" }",{"type":20,"value":333},".",{"type":14,"tag":23,"props":335,"children":336},{},[337],{"type":14,"tag":43,"props":338,"children":340},{"className":339},[],[341],{"type":20,"value":342},"\u002F\u002F representative — exact data fields are defined by the processor",{"type":14,"tag":344,"props":345,"children":346},"style",{},[347],{"type":20,"value":348},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}",{"title":7,"searchDepth":94,"depth":94,"links":350},[351,352],{"id":54,"depth":94,"text":57},{"id":142,"depth":94,"text":145},"markdown","content:docs:5.get-session.md","content","docs\u002F5.get-session.md","docs\u002F5.get-session","md",[360,363,366,367,370,373,376,379,382,385,388],{"_path":361,"title":362},"\u002Fdocs\u002Fauthentication","Authentication",{"_path":364,"title":365},"\u002Fdocs\u002Fcallbacks","Callbacks",{"_path":4,"title":8},{"_path":368,"title":369},"\u002Fdocs\u002Fgetting-started","Getting started",{"_path":371,"title":372},"\u002Fdocs\u002Finitiate","Initiate",{"_path":374,"title":375},"\u002Fdocs\u002Finquiry","Inquiry",{"_path":377,"title":378},"\u002Fdocs\u002Fpayment","Payment",{"_path":380,"title":381},"\u002Fdocs\u002Frefund","Refund",{"_path":383,"title":384},"\u002Fdocs\u002Fstatus-codes","Status codes",{"_path":386,"title":387},"\u002Fdocs\u002Fvoid","Void",{"_path":389,"title":390},"\u002Fdocs\u002Fwoocommerce","WooCommerce",[392,393,394,395,396,397,398,399,400,401,402],{"_path":368,"title":369},{"_path":361,"title":362},{"_path":371,"title":372},{"_path":377,"title":378},{"_path":4,"title":8},{"_path":374,"title":375},{"_path":380,"title":381},{"_path":386,"title":387},{"_path":364,"title":365},{"_path":383,"title":384},{"_path":389,"title":390},1787651215633]