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

Token #2

Closed
officialmahak opened this issue Jan 11, 2022 · 17 comments
Closed

Token #2

officialmahak opened this issue Jan 11, 2022 · 17 comments

Comments

@officialmahak
Copy link

Hello,

How can I get a token from my Shopify Store?

Regards

@mehulmk
Copy link
Owner

mehulmk commented Jan 12, 2022

Hello,
https://shopify.dev/apps/auth/basic-http
follow this link and generate Shopify access token for private app.
its looks like shppa_adgjgsdfsjkgdjfsgdjgh
and base url is like https://{shop}.myshopify.com/admin/api/2022-01/
Let me know if need any more help
Thanks

@officialmahak
Copy link
Author

Hello,

I change API and my Shopify URL in key_util.dart
After running this app it shows errors
https://ibb.co/R6WKcZv

Regards

@officialmahak
Copy link
Author

I already tried API, Shared Secret & Storefront access token but same issue

@CodeGetIT
Copy link

we are getting the error message

@CodeGetIT
Copy link

can you please help me out

@mehulmk
Copy link
Owner

mehulmk commented Jan 18, 2022

Sorry for late reply

1)You need to add product to you shopify data base(i have already add dummy product github link in readme file).
Screenshot 2022-01-18 at 3 41 12 PM

2)and then you need to create different collection for category, offer, banner etc
Screenshot 2022-01-18 at 3 45 01 PM

3)then replace that collection id in key_util.dart file
Screenshot 2022-01-18 at 3 57 58 PM

Screenshot 2022-01-18 at 4 01 42 PM

let me know if you need more help
Thanks

@officialmahak
Copy link
Author

Hello,

Please check
I changed all the Collection ID but the same issue

Screenshot 2022-01-18 at 10 05 37 PM

Regards

@mehulmk
Copy link
Owner

mehulmk commented Jan 29, 2022

Hello,
can you try to call this( https://{shop}.com/admin/api/2021-10/collects.json ) api in post man.
You need to pass X-Shopify-Access-Token in header.
and it must return list of all collection of your shopify database.
Like this...
Screenshot 2022-01-29 at 10 59 36 AM

And if its not return collection list then you need to do some research about way this api is not working and try to make this api working.
Once this api return the collection list then i think in your app data will reflected.
Let me know you need any more help
thanks

@officialmahak
Copy link
Author

Hello,

Thanks for help

It returns 401 error with
{
"errors": "[API] Invalid API key or access token (unrecognized login or wrong password)"
}

Regards

@mehulmk
Copy link
Owner

mehulmk commented Jan 29, 2022

It's seems like you are using wrong access token.
Token looks like shppa_adgjgsdfsjkgdjfsgdjgh this(private app token start with shppa....
So pls try to replace the token maybe after that it will be working fine.
Let me know if you need more help.
Thanks

@officialmahak
Copy link
Author

Hello,

If I enter my Example URL then its works fine and if I enter my store URL with https://{shop}.com/admin/api/2021-10/collects.json then it shows 401

Best Regards

@mehulmk
Copy link
Owner

mehulmk commented Jan 29, 2022

My example url means you store url right ?

@officialmahak
Copy link
Author

yes
https://sakurameds.myshopify.com/admin/api/2022-01/collects.json

If you want then i will privately message you my key and secret

Regards

@mehulmk
Copy link
Owner

mehulmk commented Jan 29, 2022

Right you need to use your shope url.
https://{shop}.com/admin/api/2021-10/collects.json here I hide my store domain with {shop}.
So use your url in key_util.dart.(in base_url params)

@officialmahak
Copy link
Author

Thanks

Could you please test my store keys on postman?
please drop your email or anything
i will provide you my credentials

Regards

@mehulmk
Copy link
Owner

mehulmk commented Jan 29, 2022

Sure,
I had added developer contact details in ReadMe file.

@officialmahak
Copy link
Author

Please check your Linkedin

Regards

@mehulmk mehulmk closed this as completed Feb 23, 2022
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

3 participants