I would like to know how to get an access token that can be used for calling https://api.wix.com/events/v1/orders
The idea is calling this rest API from a server with no user interaction involved.
Currently it works with a test token from https://dev.wix.com/api/rest/wix-events/wix-events/order/list-order
Thank you
Sample Code In Ruby
TOKEN = "o71isC_MZHWWZVWXVscCCqvtM_..."
def self.wix_orders(event_id)
url = "https://api.wix.com/events/v1/orders? eventId=#{event_id}&offset=0&limit=100&fieldset=DETAILS&fieldset=FORM&fieldset=TICKETS&facet=status"
json_response = HTTParty.get(url, headers: {"Authorization" => HdWixEvent::TOKEN})
response = JSON.parse(json_response&.body)
response["orders"]
end
