import{_ as d,c as r,b as s,a as o,e,w as t,d as n,r as i,o as p}from"./app-Dgsdh8A6.js";const c={};function u(D,l){const a=i("RouteLink");return p(),r("div",null,[l[16]||(l[16]=s("h1",{id:"用户注册",tabindex:"-1"},[s("a",{class:"header-anchor",href:"#用户注册"},[s("span",null,"用户注册")])],-1)),l[17]||(l[17]=s("h2",{id:"人机验证",tabindex:"-1"},[s("a",{class:"header-anchor",href:"#人机验证"},[s("span",null,"人机验证")])],-1)),s("p",null,[e(a,{to:"/docs/login/login_action/#%E9%AA%8C%E8%AF%81%E7%99%BB%E5%BD%95"},{default:t(()=>l[0]||(l[0]=[n("完成人机验证(参考验证登录)")])),_:1,__:[0]})]),l[18]||(l[18]=s("p",null,[n("完成后得到"),s("code",null,"key"),n(", "),s("code",null,"challenge"),n(", "),s("code",null,"validate"),n(", "),s("code",null,"seccode"),n("四个参数")],-1)),l[19]||(l[19]=s("h2",{id:"发送短信验证码",tabindex:"-1"},[s("a",{class:"header-anchor",href:"#发送短信验证码"},[s("span",null,"发送短信验证码")])],-1)),s("p",null,[e(a,{to:"/docs/login/login_action/SMS.html#%E5%8F%91%E9%80%81%E7%9F%AD%E4%BF%A1%E9%AA%8C%E8%AF%81%E7%A0%81%EF%BC%88web%E7%AB%AF%EF%BC%89"},{default:t(()=>l[1]||(l[1]=[n("发送短信验证码(参考短信登录)")])),_:1,__:[1]})]),l[20]||(l[20]=o(`<p><strong>注意不同的是这里type=1而非21</strong>,推测此参数决定短信内容</p><div class="language-bash line-numbers-mode" data-highlighter="shiki" data-ext="bash" style="background-color:#1E1E1E;color:#D4D4D4;"><pre class="shiki dark-plus vp-code"><code class="language-bash"><span class="line"><span style="color:#DCDCAA;">curl</span><span style="color:#CE9178;"> &#39;https://passport.bilibili.com/web/sms/general/v2/send&#39;</span><span style="color:#D7BA7D;"> \\ </span></span>
<span class="line"><span style="color:#DCDCAA;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;key=6eeb28e7bbd64b389da2be3a2778c7e3&#39;</span><span style="color:#D7BA7D;"> \\</span></span>
<span class="line"><span style="color:#569CD6;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;captchaType=6&#39;</span><span style="color:#D7BA7D;"> \\</span></span>
<span class="line"><span style="color:#569CD6;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;type=1&#39;</span><span style="color:#D7BA7D;"> \\</span></span>
<span class="line"><span style="color:#569CD6;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;cid=1&#39;</span><span style="color:#D7BA7D;"> \\</span></span>
<span class="line"><span style="color:#569CD6;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;tel=13888888888&#39;</span><span style="color:#D7BA7D;"> \\</span></span>
<span class="line"><span style="color:#569CD6;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;challenge=c52148f88a28b6011db52bb213483ee8&#39;</span><span style="color:#D7BA7D;"> \\</span></span>
<span class="line"><span style="color:#569CD6;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;validate=a98841cd6ea58e1b1f5783fca73cddb6&#39;</span><span style="color:#D7BA7D;"> \\</span></span>
<span class="line"><span style="color:#569CD6;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;seccode=a98841cd6ea58e1b1f5783fca73cddb6|jordan&#39;</span></span></code></pre><div class="line-numbers" aria-hidden="true" style="counter-reset:line-number 0;"><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div></div></div><details><summary>查看示例</summary><div class="language-json line-numbers-mode" data-highlighter="shiki" data-ext="json" style="background-color:#1E1E1E;color:#D4D4D4;"><pre class="shiki dark-plus vp-code"><code class="language-json"><span class="line"><span style="color:#D4D4D4;">{</span></span>
<span class="line"><span style="color:#9CDCFE;">    &quot;code&quot;</span><span style="color:#D4D4D4;">: </span><span style="color:#B5CEA8;">0</span><span style="color:#D4D4D4;">,</span></span>
<span class="line"><span style="color:#9CDCFE;">    &quot;message&quot;</span><span style="color:#D4D4D4;">: </span><span style="color:#CE9178;">&quot;验证码短信已下发&quot;</span></span>
<span class="line"><span style="color:#D4D4D4;">}</span></span></code></pre><div class="line-numbers" aria-hidden="true" style="counter-reset:line-number 0;"><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div></div></div></details><h2 id="提交注册请求" tabindex="-1"><a class="header-anchor" href="#提交注册请求"><span>提交注册请求</span></a></h2><blockquote><p>https://passport.bilibili.com/web/reg/tel</p></blockquote><p><em>请求方式：POST</em></p><p><strong>正文参数（ application/x-www-form-urlencoded ）：</strong></p>`,7)),s("table",null,[l[15]||(l[15]=s("thead",null,[s("tr",null,[s("th",null,"参数名"),s("th",null,"类型"),s("th",null,"内容"),s("th",null,"必要性"),s("th",null,"备注")])],-1)),s("tbody",null,[s("tr",null,[l[5]||(l[5]=s("td",null,"cid",-1)),l[6]||(l[6]=s("td",null,"num",-1)),l[7]||(l[7]=s("td",null,"国际冠字码",-1)),l[8]||(l[8]=s("td",null,"必要",-1)),s("td",null,[l[3]||(l[3]=n("可以从 ")),e(a,{to:"/docs/login/login_action/SMS.html#%E8%8E%B7%E5%8F%96%E5%9B%BD%E9%99%85%E5%86%A0%E5%AD%97%E7%A0%81_web%E7%AB%AF"},{default:t(()=>l[2]||(l[2]=[n("获取国际冠字码")])),_:1,__:[2]}),l[4]||(l[4]=n(" 接口中获取"))])]),l[9]||(l[9]=s("tr",null,[s("td",null,"tel"),s("td",null,"num"),s("td",null,"手机号码"),s("td",null,"必要"),s("td")],-1)),l[10]||(l[10]=s("tr",null,[s("td",null,"code"),s("td",null,"num"),s("td",null,"短信验证码"),s("td",null,"必要"),s("td")],-1)),l[11]||(l[11]=s("tr",null,[s("td",null,"nickName"),s("td",null,"str"),s("td",null,"昵称"),s("td",null,"必要"),s("td")],-1)),l[12]||(l[12]=s("tr",null,[s("td",null,"pwd"),s("td",null,"str"),s("td",null,"密码"),s("td",null,"必要"),s("td",null,"密码为明文")],-1)),l[13]||(l[13]=s("tr",null,[s("td",null,"plat"),s("td",null,"num"),s("td",null,"0"),s("td",null,"必要"),s("td",null,"平台？")],-1)),l[14]||(l[14]=s("tr",null,[s("td",null,"gourl"),s("td",null,"str"),s("td",null,"注册成功跳转地址"),s("td",null,"非必要"),s("td",null,[n("默认为主页"),s("code",null,"https://www.bilibili.com/")])],-1))])]),l[21]||(l[21]=o(`<p><strong>json回复：</strong></p><p>根对象：</p><table><thead><tr><th>字段</th><th>类型</th><th>内容</th><th>备注</th></tr></thead><tbody><tr><td>code</td><td>num</td><td>返回值</td><td>0：成功<br>1005：验证码错误<br>1007：验证码过期</td></tr><tr><td>message</td><td>str</td><td>错误信息</td><td>成功时无此字段</td></tr><tr><td>data</td><td>obj</td><td>信息本体</td><td>只在成功时存在</td></tr></tbody></table><p><code>data</code>对象：</p><table><thead><tr><th>字段</th><th>类型</th><th>内容</th><th>备注</th></tr></thead><tbody><tr><td>redirectUrl</td><td>str</td><td>跳转链接</td><td></td></tr><tr><td>hint</td><td>str</td><td>&quot;注册成功&quot;</td><td>成功后不提示成功还能提示什么?</td></tr><tr><td>in_reg_audit</td><td>num</td><td>(?)</td><td></td></tr></tbody></table><div class="language-bash line-numbers-mode" data-highlighter="shiki" data-ext="bash" style="background-color:#1E1E1E;color:#D4D4D4;"><pre class="shiki dark-plus vp-code"><code class="language-bash"><span class="line"><span style="color:#DCDCAA;">curl</span><span style="color:#CE9178;"> &#39;https://passport.bilibili.com/web/reg/tel&#39;</span><span style="color:#D7BA7D;"> \\</span></span>
<span class="line"><span style="color:#569CD6;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;plat=0&#39;</span><span style="color:#D7BA7D;"> \\</span></span>
<span class="line"><span style="color:#569CD6;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;cid=1&#39;</span><span style="color:#D7BA7D;"> \\</span></span>
<span class="line"><span style="color:#569CD6;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;tel=13888888888&#39;</span><span style="color:#D7BA7D;"> \\</span></span>
<span class="line"><span style="color:#569CD6;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;code=121314&#39;</span><span style="color:#D7BA7D;"> \\</span></span>
<span class="line"><span style="color:#569CD6;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;nickName=萌系小妹纸わ&#39;</span></span>
<span class="line"><span style="color:#DCDCAA;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;pwd=Password1234&#39;</span><span style="color:#D7BA7D;"> \\</span></span>
<span class="line"><span style="color:#569CD6;">    --data-urlencode</span><span style="color:#CE9178;"> &#39;gourl=https://www.bilibili.com&#39;</span></span></code></pre><div class="line-numbers" aria-hidden="true" style="counter-reset:line-number 0;"><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div></div></div><details><summary>查看示例</summary><div class="language-json line-numbers-mode" data-highlighter="shiki" data-ext="json" style="background-color:#1E1E1E;color:#D4D4D4;"><pre class="shiki dark-plus vp-code"><code class="language-json"><span class="line"><span style="color:#D4D4D4;">{</span></span>
<span class="line"><span style="color:#9CDCFE;">    &quot;code&quot;</span><span style="color:#D4D4D4;">: </span><span style="color:#B5CEA8;">0</span><span style="color:#D4D4D4;">,</span></span>
<span class="line"><span style="color:#9CDCFE;">    &quot;data&quot;</span><span style="color:#D4D4D4;">: {</span></span>
<span class="line"><span style="color:#9CDCFE;">        &quot;redirectUrl&quot;</span><span style="color:#D4D4D4;">: </span><span style="color:#CE9178;">&quot;https://www.bilibili.com&quot;</span><span style="color:#D4D4D4;">,</span></span>
<span class="line"><span style="color:#9CDCFE;">        &quot;hint&quot;</span><span style="color:#D4D4D4;">: </span><span style="color:#CE9178;">&quot;注册成功&quot;</span><span style="color:#D4D4D4;">,</span></span>
<span class="line"><span style="color:#9CDCFE;">        &quot;in_reg_audit&quot;</span><span style="color:#D4D4D4;">: </span><span style="color:#B5CEA8;">0</span></span>
<span class="line"><span style="color:#D4D4D4;">    }</span></span>
<span class="line"><span style="color:#D4D4D4;">}</span></span></code></pre><div class="line-numbers" aria-hidden="true" style="counter-reset:line-number 0;"><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div></div></div></details>`,7))])}const b=d(c,[["render",u]]),y=JSON.parse('{"path":"/docs/user/register.html","title":"用户注册","lang":"zh-CN","frontmatter":{},"git":{"updatedTime":1726759053000,"contributors":[{"name":"SocialSisterYi","username":"SocialSisterYi","email":"1440239038@qq.com","commits":3,"url":"https://github.com/SocialSisterYi"},{"name":"SessionHu","username":"SessionHu","email":"102411014+SessionHu@users.noreply.github.com","commits":1,"url":"https://github.com/SessionHu"}],"changelog":[{"hash":"1e24c6b1889160c4c35c01416aa4239501accf5f","time":1726759053000,"email":"102411014+SessionHu@users.noreply.github.com","author":"Session小胡","message":"调整部分接口描述与错误修复 (#1088)","coAuthors":[{"name":"社会易姐QwQ","email":"45892418+SocialSisterYi@users.noreply.github.com"}]},{"hash":"f6760f4be38d5b592d396b211e48c666286524de","time":1677124138000,"email":"1440239038@qq.com","author":"SocialSisterYi","message":"🔨remove header index"},{"hash":"7d89ece2ac46425810647c4ac92acf5f3721cb68","time":1676998806000,"email":"1440239038@qq.com","author":"SocialSisterYi","message":"🚀调整项目结构"}]},"filePathRelative":"docs/user/register.md"}');export{b as comp,y as data};
