次のカールを通常のhttp要求に変換する方法はありますか?郵便配達中に提供されるこの(http要求のためのポストマンを使用して)cURLのHTTP認証に相当username:password
GET https://{username}.fred.sensetecnic.com/api/{custom_endpoint_name}
Headers: Username: username, Password: password
次のカールを通常のhttp要求に変換する方法はありますか?郵便配達中に提供されるこの(http要求のためのポストマンを使用して)cURLのHTTP認証に相当username:password
GET https://{username}.fred.sensetecnic.com/api/{custom_endpoint_name}
Headers: Username: username, Password: password
使用Basic Auth
のようなものに
curl --user <username>:<password> https://{username}.fred.sensetecnic.com/api/{custom_endpoint_name}
。
Authorization
タブです。Basic Auth
を選択します。注:これが機能するためには、サーバはJSONエンコードされた資格情報を受け入れる必要があります。
を追加しますか。その2番目のスニペットは、私が見たようなhttpリクエストのようには見えません。あなたは読んでいる:https://tools.ietf.org/html/rfc7617 – Evert
申し訳ありませんが、コードブラケットが混乱してしまった場合。コマンドラインコードではありません。つまり、curlが提供する:の代わりにヘッダーを使用する方法があります。 –
Delonous