PageSourceSearch

https://openbao.org/assets/js/c512cc43.8a8f3643.js

js openbao.org collected 2026-10-02 06:35:40 UTC 4,510 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([["17268"],{19183(e,n,s){s.r(n),s.d(n,{metadata:()=>a,default:()=>c,frontMatter:()=>p,contentTitle:()=>i,toc:()=>d,assets:()=>l});var a=JSON.parse('{"id":"api/system/wrapping-wrap","title":"/sys/wrapping/wrap","description":"The `/sys/wrapping/wrap` endpoint wraps the given values in a\\nresponse-wrapped token.","source":"@site/content/docs/api/system/wrapping-wrap.mdx","sourceDirName":"api/system","slug":"/api/system/wrapping-wrap","permalink":"/docs/next/api/system/wrapping-wrap","draft":false,"unlisted":false,"editUrl":"https://github.com/openbao/openbao/blob/main/website/content/docs/api/system/wrapping-wrap.mdx","tags":[],"version":"current","frontMatter":{"description":"The `/sys/wrapping/wrap` endpoint wraps the given values in a\\nresponse-wrapped token."},"sidebar":"api","previous":{"title":"/sys/wrapping/unwrap","permalink":"/docs/next/api/system/wrapping-unwrap"}}'),r=s(94686),t=s(44812);let p={description:"The `/sys/wrapping/wrap` endpoint wraps the given values in a\nresponse-wrapped token."},i="/sys/wrapping/wrap",l={},d=[{value:"Wrapping wrap",id:"wrapping-wrap",level:2},{value:"Parameters",id:"parameters",level:3},{value:"Sample payload",id:"sample-payload",level:3},{value:"Sample request",id:"sample-request",level:3},{value:"Sample response",id:"sample-response",level:3}];function o(e){let n={code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",li:"li",p:"p",pre:"pre",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,t.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.header,{children:(0,r.jsx)(n.h1,{id:"syswrappingwrap",children:(0,r.jsx)(n.code,{children:"/sys/wrapping/wrap"})})}),"\n",(0,r.jsxs)(n.p,{children:["The ",(0,r.jsx)(n.code,{children:"/sys/wrapping/wrap"})," endpoint wraps the given values in a response-wrapped\ntoken."]}),"\n",(0,r.jsx)(n.h2,{id:"wrapping-wrap",children:"Wrapping wrap"}),"\n",(0,r.jsx)(n.p,{children:"This endpoint wraps the given user-supplied data inside a response-wrapped\ntoken."}),"\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Method"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Path"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"POST"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"/sys/wrapping/wrap"})})]})})]}),"\n",(0,r.jsx)(n.h3,{id:"parameters",children:"Parameters"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.code,{children:":any"})," ",(0,r.jsx)(n.code,{children:"(map<string|string>: nil)"})," \u2013\xa0Parameters should be supplied as\nkeys/values in a JSON object. The exact set of given parameters will be\ncontained in the wrapped response."]}),"\n"]}),"\n",(0,r.jsx)(n.h3,{id:"sample-payload",children:"Sample payload"}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-json",children:'{\n  "foo": "bar",\n  "zip": "zap"\n}\n'})}),"\n",(0,r.jsx)(n.h3,{id:"sample-request",children:"Sample request"}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-shell-session",children:'$ curl \\\n    --header "X-Vault-Token: ..." \\\n    --header "X-Vault-Wrap-TTL: 60" \\\n    --request POST \\\n    --data @payload.json \\\n    http://127.0.0.1:8200/v1/sys/wrapping/wrap\n'})}),"\n",(0,r.jsx)(n.h3,{id:"sample-response",children:"Sample response"}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-json",children:'{\n  "request_id": "",\n  "lease_id": "",\n  "lease_duration": 0,\n  "renewable": false,\n  "data": null,\n  "warnings": null,\n  "wrap_info": {\n    "token": "fb79b9d3-d94e-9eb6-4919-c559311133d6",\n    "ttl": 300,\n    "creation_time": "2016-09-28T14:41:00.56961496-04:00",\n    "creation_path": "sys/wrapping/wrap"\n  }\n}\n'})})]})}function c(e={}){let{wrapper:n}={...(0,t.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(o,{...e})}):o(e)}},44812(e,n,s){s.d(n,{R:()=>p,x:()=>i});var a=s(92990);let r={},t=a.createContext(r);function p(e){let n=a.useContext(t);return a.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function i(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:p(e.components),a.createElement(t.Provider,{value:n},e.children)}}}]);

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.