Skip to content

SDKs / wrapper libraries

1 result found

  1. Issue on Put method for creating a tracking option - Python

    I want to create a tracking option ((i.e) Add tracking option) under the respective tracking category, using Xero tracking category API for my organisation. But while creating data using 'put' Requests method, it is not creating.

    I am using the below condition in python:

    response = requests.put(url=url, auth=oauth, data=xml_string)

    I want to know, what is the format for the data to be updated in the requests, for both content type xml/text and application/json.

    xml_string and url, I given is below:

    xmlstring='<Option><Name>S11963</Name></Option>'
    url = 'https://api.xero.com/api.xro/2.0/TrackingCategories/{Tracking
    Category}/Options'

    where Tracking_Category='620815a2-a7c6-4b85-8b01-ffb254ab34ad'

    Error: <ApiException xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">\r\n <ErrorNumber>500</ErrorNumber>\r\n <Type>UnknownErrorException</Type>\r\n <Message>An error occurred in Xero.…

    2 votes
    Vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    You have left! (?) (thinking…)
    0 comments  ·  Python  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  • Don't see your idea?

SDKs / wrapper libraries

Categories

Feedback and Knowledge Base