💎一站式轻松地调用各大LLM模型接口,支持GPT4、智谱、星火、月之暗面及文生图 广告
# PostJson `PostJson(Url, Body, [Options]) {WebResponse}` `Url - {String}` `Body - {Variant}` Array, Collection, or Dictionary to post `Options - {Dictionary}` *可选* Headers, Cookies, QuerystringParams, and UrlSegments * `Headers`, `Cookies`, `QuerystringParams`: `Collection `of `KeyValue `(Create with `WebHelpers.CreateKeyValue`) * `UrlSegments: Dictionary` 将JSON Body(数组,集合,字典)发布到给定的URL(带有Headers,Cookies,QuerystringParams和UrlSegments的选项)。 ``` Dim Client As New WebClient Dim Url As String Url = "https://api.example.com/v1/messages/1" ' Body ' Array, Collection, or Dictionary Dim Body As New Dictionary Body.Add "message", "Howdy!" Dim Response As WebResponse Set Response = Client.PostJson(Url, Body) Dim Headers As New Collection Headers.Add WebHelpers.CreateKeyValue("Authorization", "Bearer ...") Dim Options As New Dictionary Options.Add "Headers", Headers Set Response = Client.PostJson(Url, Body, Options) ```