Amount no longer required on DraftOrderAppliedDiscountInput

Highlighted
Tourist
5 1 0

Hi,

according this article from 17.4.2020 (https://shopify.dev/changelog/amount-no-longer-required-on-draftorderapplieddiscountinput ) amount doesn't have to be included in DraftOrder. I did try it in Insomnia, it works. But even I changed API version to "2020-4" and updated shopifyAPI python package to the latest (7.0.3), I still get VersionNotFoundError (shopify.api_version.VersionNotFoundError) when I use:

client = shopify.GraphQL()
result = client.execute(...)

Does somebody have same issue? Could you please point me in the right direction, please...

0 Likes
Highlighted
Shopify Staff
Shopify Staff
1040 139 163

Hey @tystar 

 

Try setting the version to 2020-04 instead of 2020-4.

 

If you hit the same error, please provide some sample code.

0 Likes
Highlighted
Tourist
5 1 0

Hey @scottydont ,

thanks for the reply, I had typo in the previous post, I do have API version "2020-04" in my code... Please see the python Shopify API code: https://github.com/Shopify/shopify_python_api/blob/master/shopify/api_version.py 

    @classmethod
    def define_known_versions(cls):
        cls.define_version(Unstable())
        cls.define_version(Release('2019-04'))
        cls.define_version(Release('2019-07'))
        cls.define_version(Release('2019-10'))
        cls.define_version(Release('2020-01'))

Doesn't contain the newest version "2020-04"...

0 Likes
Highlighted
Shopify Staff
Shopify Staff
1040 139 163

Hey @tystar 

 

It looks like 2020-04 was just added today. Try the latest version.

1 Like
Highlighted

Hi @scottydont,

I'm having a similar issue so I decided to record an example in Insomnia. Basically the API requires the amount field regardless the API version when using the API directly. Could you please take a look?

https://www.loom.com/share/ac861526f46d467fa9129b848c563e80

 

Thank you,

Josef

 

 

0 Likes
Highlighted
Shopify Staff
Shopify Staff
1040 139 163

Thanks for the example @Josef_Rousek. I'm able to replicate. We're looking into this.

1 Like
Highlighted
Shopify Staff
Shopify Staff
1040 139 163

@Josef_Rousek this has been resolved.

0 Likes