AutoIt
AutoIt
Shopware Digest Authentication
See more Shopware Examples
Demonstrates using Digest access authentication for Shopware.Chilkat AutoIt Downloads
Local $bSuccess = False
; This example assumes the Chilkat API to have been previously unlocked.
; See Global Unlock Sample for sample code.
$oHttp = ObjCreate("Chilkat.Http")
; To use HTTP Digest Authentication, set the login and password, and also indicate that DigestAuth should be used.
$oHttp.Login = "api_username"
$oHttp.Password = "api_key"
$oHttp.DigestAuth = True
$oSbResponseBody = ObjCreate("Chilkat.StringBuilder")
$bSuccess = $oHttp.QuickGetSb("https://my-shopware-shop.com/api/articles?limit=2",$oSbResponseBody)
If ($bSuccess = False) Then
ConsoleWrite($oHttp.LastErrorText & @CRLF)
Exit
EndIf
$oJResp = ObjCreate("Chilkat.JsonObject")
$oJResp.LoadSb($oSbResponseBody)
$oJResp.EmitCompact = False
ConsoleWrite("Response Body:" & @CRLF)
ConsoleWrite($oJResp.Emit() & @CRLF)