Chilkat Examples

ChilkatHOME.NET Core C#Android™AutoItCC#C++Chilkat2-PythonCkPythonClassic ASPDataFlexDelphi ActiveXDelphi DLLGoJavaLianjaMono C#Node.jsObjective-CPHP ActiveXPHP ExtensionPerlPowerBuilderPowerShellPureBasicRubySQL ServerSwift 2Swift 3,4,5...TclUnicode CUnicode C++VB.NETVBScriptVisual Basic 6.0Visual FoxProXojo Plugin

AutoIt Web API Examples

Primary Categories

ABN AMRO
AWS Secrets Manager
AWS Security Token Service
AWS Translate
Activix CRM
Adyen
Alibaba Cloud OSS
Amazon Cognito
Amazon DynamoDB
Amazon MWS
Amazon Pay
Amazon Rekognition
Amazon SP-API
Amazon Voice ID
Aruba Fatturazione
Azure Maps
Azure Monitor
Azure OAuth2
Azure Storage Accounts
Backblaze S3
Banco Inter
Belgian eHealth Platform
Bitfinex v2 REST
Bluzone
BrickLink
Bunny CDN
CallRail
CardConnect
Cerved
ClickBank
Clickatell
Cloudfare
Constant Contact
DocuSign
Duo Auth MFA
ETrade
Ecwid
Egypt ITIDA
Egypt eReceipt
Etsy
Facebook
Faire
Frame.io
GeoOp
GetHarvest
Global Payments
Google People
Google Search Console
Google Translate
Google Vision
Hungary NAV Invoicing
IBM Text to Speech
Ibanity
IntakeQ
JCC Cyprus
Jira
Lightspeed
MYOB
Magento
Mailgun
Malaysia MyInvois

Mastercard
MedTunnel
MercadoLibre
MessageMedia
Microsoft Calendar
Microsoft Group
Microsoft Tasks and Plans
Microsoft Teams
Moody's
Okta OAuth/OIDC
OneLogin OIDC
OneNote
OpenAI ChatGPT
PRODA
PayPal
Paynow.pl
Peoplevox
Populi
QuickBooks
Rabobank
Refinitiv
Royal Mail OBA
SCiS Schools Catalogue
SII Chile
SMSAPI
SOAP finkok.com
Salesforce
SendGrid
Shippo
Shopify
Shopware
Shopware 6
SimpleTexting
Square
Stripe
SugarCRM
TicketBAI
TikTok Shop
Trello
Twilio
Twitter API v2
Twitter v1
UPS
UniPin
VoiceBase
Vonage
WaTrend
Walmart v3
Wasabi
WhatsApp
WiX
WooCommerce
WordPress
Xero
Yahoo Mail
Yapily
Yousign
ZATCA
Zendesk
Zoom
_Miscellaneous_
eBay
effectconnect
hacienda.go.cr

 

 

 

(AutoIt) ClickBank Parse Instant Notification JSON

Demonstrates how to parse the JSON of a ClickBank instant notification.

Chilkat ActiveX Downloads

ActiveX for 32-bit and 64-bit Windows

$oJson = ObjCreate("Chilkat.JsonObject")

$oJson.Load("{  ...  }")

; Use this online tool to generate parsing code from sample JSON: 
; Generate Parsing Code from JSON

; See the parsing code below..

; Sample notification JSON: 

; {
;     "transactionTime": "2016-06-05T13:47:51-06:00",
;     "receipt": "CWOGBZLN",
;     "transactionType": "SALE",
;     "vendor": "testacct",
;     "affiliate": "affiliate1",
;     "role": "VENDOR",
;     "totalAccountAmount": 0.00,
;     "paymentMethod": "VISA",
;     "totalOrderAmount": 0.00,
;     "totalTaxAmount": 0.00,
;     "totalShippingAmount": 0.00,
;     "currency": "USD",
;     "orderLanguage": "EN",
;     "trackingCodes": [
;         "tracking_code"
;     ],
;     "lineItems": [
;         {
;             "itemNo": "1",
;             "productTitle": "Product Title",
;             "shippable": false,
;             "recurring": false,
;             "accountAmount": 5.00,
;             "quantity": 1,
;             "downloadUrl": "<download_url>"
;             "lineItemType": "CART"
;        }
;         {
;             "itemNo": "2",
;             "productTitle": "Second Product",
;             "shippable": false,
;             "recurring": true,
;             "accountAmount": 2.99,
;             "quantity": 1,
;             "downloadUrl": "<download_url>"
;             "lineItemType": "CART"
;        }
; 
;     ],
;      "customer": {
;         "shipping": {
;             "firstName": "TEST",
;             "lastName": "GUY",
;             "fullName": "Test Guy",
;             "phoneNumber": "",
;             "email": "test@example.net",
;             "address": {
;                 "address1": "12 Test Lane",
;                 "address2": "Suite 100",
;                 "city": "LAS VEGAS",
;                 "county": "LAS VEGAS",
;                 "state": "NV",
;                 "postalCode": "89101",
;                 "country": "US"
;             }
;         },
;         "billing": {
;             "firstName": "TEST",
;             "lastName": "GUY",
;             "fullName": "Test Guy",
;             "phoneNumber": "",
;             "email": "test@example.net",
;             "address": {
;                 "state": "NV",
;                 "postalCode": "89101",
;                 "country": "US"
;             }
;         }
;     },
;      "upsell": {
;         "upsellOriginalReceipt": "XXXXXXXX",
;         "upsellFlowId": 55,
;         "upsellSession": "VVVVVVVVVV",
;         "upsellPath": "upsell_path"
;     },
;      "hopfeed": {
;         "hopfeedClickId": "hopfeed_click",
;         "hopfeedApplicationId": 0000,
;         "hopfeedCreativeId": 0000,
;         "hopfeedApplicationPayout": 0.00,
;         "hopfeedVendorPayout": 0.00
;     },
;      "version": 6.0,
;     "attemptCount": 1,
;      "vendorVariables": {
;        "v1": "variable1", 
;        "v2": "variable2" 
;     }
;  }
; 
; 

Local $sTransactionTime
Local $sReceipt
Local $sTransactionType
Local $sVendor
Local $sAffiliate
Local $sRole
Local $sTotalAccountAmount
Local $sPaymentMethod
Local $sTotalOrderAmount
Local $sTotalTaxAmount
Local $sTotalShippingAmount
Local $sCurrency
Local $sOrderLanguage
Local $sCustomerShippingFirstName
Local $sCustomerShippingLastName
Local $sCustomerShippingFullName
Local $sCustomerShippingPhoneNumber
Local $sCustomerShippingEmail
Local $sCustomerShippingAddressAddress1
Local $sCustomerShippingAddressAddress2
Local $sCustomerShippingAddressCity
Local $sCustomerShippingAddressCounty
Local $sCustomerShippingAddressState
Local $sCustomerShippingAddressPostalCode
Local $sCustomerShippingAddressCountry
Local $sCustomerBillingFirstName
Local $sCustomerBillingLastName
Local $sCustomerBillingFullName
Local $sCustomerBillingPhoneNumber
Local $sCustomerBillingEmail
Local $sCustomerBillingAddressState
Local $sCustomerBillingAddressPostalCode
Local $sCustomerBillingAddressCountry
Local $sUpsellUpsellOriginalReceipt
Local $iUpsellUpsellFlowId
Local $sUpsellUpsellSession
Local $sUpsellUpsellPath
Local $sHopfeedHopfeedClickId
Local $iHopfeedHopfeedApplicationId
Local $iHopfeedHopfeedCreativeId
Local $sHopfeedHopfeedApplicationPayout
Local $sHopfeedHopfeedVendorPayout
Local $sVersion
Local $iAttemptCount
Local $sVendorVariablesV1
Local $sVendorVariablesV2
Local $i
Local $iCount_i
Local $strVal
Local $sItemNo
Local $sProductTitle
Local $bShippable
Local $bRecurring
Local $sAccountAmount
Local $iQuantity
Local $sDownloadUrl
Local $sLineItemType

$sTransactionTime = $oJson.StringOf("transactionTime")
$sReceipt = $oJson.StringOf("receipt")
$sTransactionType = $oJson.StringOf("transactionType")
$sVendor = $oJson.StringOf("vendor")
$sAffiliate = $oJson.StringOf("affiliate")
$sRole = $oJson.StringOf("role")
$sTotalAccountAmount = $oJson.StringOf("totalAccountAmount")
$sPaymentMethod = $oJson.StringOf("paymentMethod")
$sTotalOrderAmount = $oJson.StringOf("totalOrderAmount")
$sTotalTaxAmount = $oJson.StringOf("totalTaxAmount")
$sTotalShippingAmount = $oJson.StringOf("totalShippingAmount")
$sCurrency = $oJson.StringOf("currency")
$sOrderLanguage = $oJson.StringOf("orderLanguage")
$sCustomerShippingFirstName = $oJson.StringOf("customer.shipping.firstName")
$sCustomerShippingLastName = $oJson.StringOf("customer.shipping.lastName")
$sCustomerShippingFullName = $oJson.StringOf("customer.shipping.fullName")
$sCustomerShippingPhoneNumber = $oJson.StringOf("customer.shipping.phoneNumber")
$sCustomerShippingEmail = $oJson.StringOf("customer.shipping.email")
$sCustomerShippingAddressAddress1 = $oJson.StringOf("customer.shipping.address.address1")
$sCustomerShippingAddressAddress2 = $oJson.StringOf("customer.shipping.address.address2")
$sCustomerShippingAddressCity = $oJson.StringOf("customer.shipping.address.city")
$sCustomerShippingAddressCounty = $oJson.StringOf("customer.shipping.address.county")
$sCustomerShippingAddressState = $oJson.StringOf("customer.shipping.address.state")
$sCustomerShippingAddressPostalCode = $oJson.StringOf("customer.shipping.address.postalCode")
$sCustomerShippingAddressCountry = $oJson.StringOf("customer.shipping.address.country")
$sCustomerBillingFirstName = $oJson.StringOf("customer.billing.firstName")
$sCustomerBillingLastName = $oJson.StringOf("customer.billing.lastName")
$sCustomerBillingFullName = $oJson.StringOf("customer.billing.fullName")
$sCustomerBillingPhoneNumber = $oJson.StringOf("customer.billing.phoneNumber")
$sCustomerBillingEmail = $oJson.StringOf("customer.billing.email")
$sCustomerBillingAddressState = $oJson.StringOf("customer.billing.address.state")
$sCustomerBillingAddressPostalCode = $oJson.StringOf("customer.billing.address.postalCode")
$sCustomerBillingAddressCountry = $oJson.StringOf("customer.billing.address.country")
$sUpsellUpsellOriginalReceipt = $oJson.StringOf("upsell.upsellOriginalReceipt")
$iUpsellUpsellFlowId = $oJson.IntOf("upsell.upsellFlowId")
$sUpsellUpsellSession = $oJson.StringOf("upsell.upsellSession")
$sUpsellUpsellPath = $oJson.StringOf("upsell.upsellPath")
$sHopfeedHopfeedClickId = $oJson.StringOf("hopfeed.hopfeedClickId")
$iHopfeedHopfeedApplicationId = $oJson.IntOf("hopfeed.hopfeedApplicationId")
$iHopfeedHopfeedCreativeId = $oJson.IntOf("hopfeed.hopfeedCreativeId")
$sHopfeedHopfeedApplicationPayout = $oJson.StringOf("hopfeed.hopfeedApplicationPayout")
$sHopfeedHopfeedVendorPayout = $oJson.StringOf("hopfeed.hopfeedVendorPayout")
$sVersion = $oJson.StringOf("version")
$iAttemptCount = $oJson.IntOf("attemptCount")
$sVendorVariablesV1 = $oJson.StringOf("vendorVariables.v1")
$sVendorVariablesV2 = $oJson.StringOf("vendorVariables.v2")
$i = 0
$iCount_i = $oJson.SizeOfArray("trackingCodes")
While $i < $iCount_i
    $oJson.I = $i
    $strVal = $oJson.StringOf("trackingCodes[i]")
    $i = $i + 1
Wend
$i = 0
$iCount_i = $oJson.SizeOfArray("lineItems")
While $i < $iCount_i
    $oJson.I = $i
    $sItemNo = $oJson.StringOf("lineItems[i].itemNo")
    $sProductTitle = $oJson.StringOf("lineItems[i].productTitle")
    $bShippable = $oJson.BoolOf("lineItems[i].shippable")
    $bRecurring = $oJson.BoolOf("lineItems[i].recurring")
    $sAccountAmount = $oJson.StringOf("lineItems[i].accountAmount")
    $iQuantity = $oJson.IntOf("lineItems[i].quantity")
    $sDownloadUrl = $oJson.StringOf("lineItems[i].downloadUrl")
    $sLineItemType = $oJson.StringOf("lineItems[i].lineItemType")
    $i = $i + 1
Wend

 

© 2000-2024 Chilkat Software, Inc. All Rights Reserved.