Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unprocessable Entity on adding Application Charges #6

Open
kurtommy opened this issue Jan 3, 2013 · 1 comment
Open

Unprocessable Entity on adding Application Charges #6

kurtommy opened this issue Jan 3, 2013 · 1 comment

Comments

@kurtommy
Copy link

kurtommy commented Jan 3, 2013

Hi to all,

I recive an error on running this code present in the example:

Unprocessable Entity - 422

$charge = array
(
"recurring_application_charge"=>array
(
"price"=>10.0,
"name"=>"Super Duper Plan",
"return_url"=>"http://super-duper.shopifyapps.com",
"test"=>true
)
);

    try
    {
        // All requests accept an optional fourth parameter, that is populated with the response headers.
        $recurring_application_charge = $shopify('POST', '/admin/recurring_application_charges.json', $charge, $response_headers);

        // API call limit helpers
        echo shopify_calls_made($response_headers); // 2
        echo shopify_calls_left($response_headers); // 298
        echo shopify_call_limit($response_headers); // 300

    }
    catch (ShopifyApiException $e)
    {
        // If you're here, either HTTP status code was >= 400 or response contained the key 'errors'
    }

Some suggestion?

@gustavomanolo
Copy link

Hi, i'm having the same error, do you have any solution about this?
Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants