PageSourceSearch

https://www.v2fly.org/assets/api.html-D9UtCJjF.js

js v2fly.org collected 2026-10-03 19:31:21 UTC 5,711 bytes, 9 lines download raw bytes

1import{_ as i,c as r,a as n,b as l,d as s,e as a,f as o,r as p,o as d}from"./app-4Jf4iTaT.js";const u={};function c(v,e){const t=p("RouteLink");return d(),r("div",null,[e[10]||(e[10]=n("h1",{id:"remote-control-api",tabindex:"-1"},[n("a",{class:"header-anchor",href:"#remote-control-api"},[n("span",null,"Remote control API")])],-1)),e[11]||(e[11]=n("p",null,[s("Some V2Ray APIs can be opened for remote control. These APIs are based on "),n("a",{href:"https://grpc.io/",target:"_blank",rel:"noopener noreferrer"},"gRPC"),s(". This API is mostly for advanced users.")],-1)),n("p",null,[e[1]||(e[1]=s("When remote control is turned on, V2Ray will build an outbound proxy by itself, which is identified by the value of the ")),e[2]||(e[2]=n("code",null,"tag",-1)),e[3]||(e[3]=s(" configuration. The user must manually point all inbound gRPC connections to this outbound proxy through ")),a(t,{to:"/en_US/config/routing.html"},{default:o(()=>e[0]||(e[0]=[s("routing")])),_:1}),e[4]||(e[4]=s("."))]),e[12]||(e[12]=l(`<h2 id="apiobject" tabindex="-1"><a class="header-anchor" href="#apiobject"><span>ApiObject</span></a></h2><p><code>ApiObject</code> corresponds to the <code>api</code> item of the configuration file.</p><div class="language-json line-numbers-mode" data-highlighter="prismjs" data-ext="json" data-title="json"><pre><code><span class="line"><span class="token punctuation">{</span></span>
2<span class="line">    <span class="token property">&quot;tag&quot;</span><span class="token operator">:</span> <span class="token string">&quot;api&quot;</span><span class="token punctuation">,</span></span>
3<span class="line">    <span class="token property">&quot;services&quot;</span><span class="token operator">:</span> <span class="token punctuation">[</span></span>
4<span class="line">        <span class="token string">&quot;HandlerService&quot;</span><span class="token punctuation">,</span></span>
5<span class="line">        <span class="token string">&quot;LoggerService&quot;</span><span class="token punctuation">,</span></span>
6<span class="line">        <span class="token string">&quot;StatsService&quot;</span></span>
7<span class="line">    <span class="token punctuation">]</span></span>
8<span class="line"><span class="token punctuation">}</span></span>
9<span class="line"></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><blockquote><p><code>tag</code>: string</p></blockquote><p>Outbound proxy ID.</p><blockquote><p><code>services</code>: [string]</p></blockquote><p>The list of available APIs, see <a href="#list-of-supported-apis">API list</a> for details.</p><h2 id="list-of-supported-apis" tabindex="-1"><a class="header-anchor" href="#list-of-supported-apis"><span>List of supported APIs</span></a></h2><h3 id="handlerservice" tabindex="-1"><a class="header-anchor" href="#handlerservice"><span>HandlerService</span></a></h3><p>Some of the APIs that modify the inbound and outbound proxy:</p><ul><li>Add a new inbound proxy;</li><li>Add a new outbound proxy;</li><li>Delete an existing inbound proxy;</li><li>Delete an existing outbound proxy;</li><li>Add a user to an inbound proxy (only support VMess, VLESS, Trojan);</li><li>Delete a user in an inbound proxy (only support VMess, VLESS, Trojan);</li></ul><h3 id="loggerservice" tabindex="-1"><a class="header-anchor" href="#loggerservice"><span>LoggerService</span></a></h3><p>Supports the restart of the built-in Logger, and can cooperate with logrotate to perform some operations on the log file.</p><h3 id="statsservice" tabindex="-1"><a class="header-anchor" href="#statsservice"><span>StatsService</span></a></h3>`,14)),n("p",null,[e[6]||(e[6]=s("The built-in data statistics service, please refer to ")),a(t,{to:"/en_US/config/stats.html"},{default:o(()=>e[5]||(e[5]=[s("Statistics")])),_:1}),e[7]||(e[7]=s(" for details."))]),e[13]||(e[13]=n("h3",{id:"observatoryservice",tabindex:"-1"},[n("a",{class:"header-anchor",href:"#observatoryservice"},[n("span",null,"ObservatoryService")])],-1)),n("p",null,[a(t,{to:"/en_US/config/observatory.html"},{default:o(()=>e[8]||(e[8]=[s("Connection Observatory")])),_:1}),e[9]||(e[9]=s(" API (v4.38.0+)."))])])}const g=i(u,[["render",c],["__file","api.html.vue"]]),h=JSON.parse('{"path":"/en_US/config/api.html","title":"Remote control API","lang":"en-US","frontmatter":{},"headers":[{"level":2,"title":"ApiObject","slug":"apiobject","link":"#apiobject","children":[]},{"level":2,"title":"List of supported APIs","slug":"list-of-supported-apis","link":"#list-of-supported-apis","children":[{"level":3,"title":"HandlerService","slug":"handlerservice","link":"#handlerservice","children":[]},{"level":3,"title":"LoggerService","slug":"loggerservice","link":"#loggerservice","children":[]},{"level":3,"title":"StatsService","slug":"statsservice","link":"#statsservice","children":[]},{"level":3,"title":"ObservatoryService","slug":"observatoryservice","link":"#observatoryservice","children":[]}]}
9],"git":{"updatedTime":1724600212000,"contributors":[{"name":"transifex-integration[bot]","username":"transifex-integration[bot]","email":"43880903+transifex-integration[bot]@users.noreply.github.com","commits":2,"url":"https://github.com/transifex-integration[bot]"},{"name":"Arınç ÜNAL","username":"Arınç ÜNAL","email":"[email protected]","commits":1,"url":"https://github.com/Arınç ÜNAL"}]},"filePathRelative":"en_US/config/api.md"}');export{g as comp,h as data};

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.