1"use strict";(globalThis.webpackChunk_atlas_docs_zen=globalThis.webpackChunk_atlas_docs_zen||[]).push([[4755],{4056(e,n,t){t.d(n,{R:()=>d,x:()=>o});var r=t(2155);const s={},i=r.createContext(s);function d(e){const n=r.useContext(i);return r.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function o(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:d(e.components),r.createElement(i.Provider,{value:n},e.children)}},5880(e,n,t){t.r(n),t.d(n,{assets:()=>c,contentTitle:()=>o,default:()=>h,frontMatter:()=>d,metadata:()=>r,toc:()=>l});const r=JSON.parse('{"id":"sdks/typescript/endpoints/delete-config","title":"deleteConfig","description":"Delete","source":"@site/docs/sdks/typescript/endpoints/delete-config.mdx","sourceDirName":"sdks/typescript/endpoints","slug":"/sdks/typescript/endpoints/delete-config","permalink":"/docs/sdks/typescript/endpoints/delete-config","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"id":"delete-config","title":"deleteConfig"},"sidebar":"sdks","previous":{"title":"createConfig","permalink":"/docs/sdks/typescript/endpoints/create-config"},"next":{"title":"retrieveConfig","permalink":"/docs/sdks/typescript/endpoints/retrieve-config"}}');var s=t(5723),i=t(4056);const d={id:"delete-config",title:"deleteConfig"},o="deleteConfig",c={},l=[{value:"Endpoint",id:"endpoint",level:2},{value:"Import",id:"import",level:2},{value:"Path Parameters",id:"path-parameters",level:2},{value:"Query Parameters",id:"query-parameters",level:2},{value:"Response Type",id:"response-type",level:2},{value:"Errors",id:"errors",level:2},{value:"Example",id:"example",level:2}];function a(e){const n={a:"a",code:"code",em:"em",h1:"h1",h2:"h2",header:"header",p:"p",pre:"pre",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,i.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.header,{children:(0,s.jsx)(n.h1,{id:"deleteconfig",children:(0,s.jsx)(n.code,{children:"deleteConfig"})})}),"\n",(0,s.jsx)(n.p,{children:"Delete"}),"\n",(0,s.jsx)(n.p,{children:"Permanently deletes a configuration object."}),"\n",(0,s.jsx)(n.h2,{id:"endpoint",children:"Endpoint"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.code,{children:"DELETE /keys/{key}/configs/{config}"})}),"\n",(0,s.jsxs)(n.p,{children:["See the ",(0,s.jsx)(n.a,{href:"/docs/api/delete-config",children:"API reference"})," for this endpoint."]}),"\n",(0,s.jsxs)(n.p,{children:["This operation needs a Management Key. Set it as ",(0,s.jsx)(n.code,{children:"userToken"})," on the client, which sends it in the ",(0,s.jsx)(n.code,{children:"Authorization"})," header. See ",(0,s.jsx)(n.a,{href:"/docs/sdks/typescript/setup",children:"setup"}),"."]}),"\n",(0,s.jsx)(n.h2,{id:"import",children:"Import"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-ts",children:'import { deleteConfig } from "@addresszen/sdk";\n'})}),"\n",(0,s.jsx)(n.h2,{id:"path-parameters",children:"Path Parameters"}),"\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{children:"Name"}),(0,s.jsx)(n.th,{children:"Type"}),(0,s.jsx)(n.th,{children:"Required"}),(0,s.jsx)(n.th,{children:"Description"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:"key"})}),(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:"string"})}),(0,s.jsx)(n.td,{children:"yes"}),(0,s.jsxs)(n.td,{children:[(0,s.jsx)(n.strong,{children:"API Key"})," The API Key to retrieve. Begins ",(0,s.jsx)(n.code,{children:"ak_"}),"."]})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:"config"})}),(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:"string"})}),(0,s.jsx)(n.td,{children:"yes"}),(0,s.jsxs)(n.td,{children:[(0,s.jsx)(n.strong,{children:"Configuration Name"})," User-provided configuration object name."]})]})]})]}),"\n",(0,s.jsx)(n.h2,{id:"query-parameters",children:"Query Parameters"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.em,{children:"None."})}),"\n",(0,s.jsx)(n.h2,{id:"response-type",children:"Response Type"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-ts",children:'import type { DeleteConfigResponse } from "@addresszen/sdk";\n'})}),"\n",(0,s.jsx)(n.h2,{id:"errors",children:"Errors"}),"\n",(0,s.jsxs)(n.p,{children:["HTTP errors throw an ",(0,s.jsx)(n.code,{children:"ApiError"})," with the HTTP ",(0,s.jsx)(n.code,{children:"status"})," and the API error ",(0,s.jsx)(n.code,{children:"code"})," and ",(0,s.jsx)(n.code,{children:"message"}),". Network failures and aborts reject with the runtime's native error. Pass ",(0,s.jsx)(n.code,{children:"throwOnError: false"})," to get ",(0,s.jsx)(n.code,{children:"{ data, error }"})," instead. See ",(0,s.jsx)(n.a,{href:"/docs/sdks/typescript/errors",children:"error handling"}),"."]}),"\n",(0,s.jsx)(n.h2,{id:"example",children:"Example"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-ts",metastring:'title="delete-config.ts"',children:'import { createZenClient, deleteConfig } from "@addresszen/sdk";\n\nexport const example = async () => {\n const client = createZenClient({\n apiKey: "ak_test",\n userToken: "uk_example",\n });\n const { data } = await deleteConfig({\n client,\n path: { key: "ak_test", config: "checkout" },\n });\n return data;\n};\n'})})]})}function h(e={}){const{wrapper:n}={...(0,i.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(a,{...e})}):a(e)}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.