Page 2 of 4

Re: Warning: You do not have permission to access the API! O

Posted: Wed Nov 18, 2015 10:26 pm
by popencart
webtiger,


what is the use if api is not getting added in the system...

Re: Warning: You do not have permission to access the API! O

Posted: Tue Nov 24, 2015 3:42 am
by ls3060
I don't know if this will help others with the API problem, but I was originally missing some of the tabs under the API page. I upgraded to 2.1 which gave me the API IP tabs and was able to fill them out, but still getting an error.

My solution was to remove the Admin side of OC from HTTPS as I have a SSL certificate. Once I did that I got no more errors.

Re: Warning: You do not have permission to access the API! O

Posted: Sun Dec 06, 2015 12:02 am
by Osiris-Warez
Install Vqmod 2.4.1 from https://code.google.com/p/vqmod/downloads/list here.

It will be ok.

Re: Warning: You do not have permission to access the API! O

Posted: Fri Dec 18, 2015 8:08 pm
by kul1010
Post by webtiger is working fine. Thanks to him. But some changes in IP address give your subscriber ip not server or client ip.

like Below you can create a list of IP's allowed to access the API. Your current IP is 122.162.60.67


Its very simple first go into System > User > API
1 Give Name To Your API Example : " Main IP "
2 Click on Generate API
3 Make it Enable

Click on API Addressees
Click on ADD IP
Copy paste your IP

Click on Save

Then Go to System > Setting > Edit Your main Store > Click on Option
See here : API User
Select Your API USER Which was created in last Stage
For Example Select " main IP "

Re: Warning: You do not have permission to access the API! O

Posted: Tue Dec 29, 2015 3:55 am
by feathersuk
ls3060 wrote:I don't know if this will help others with the API problem, but I was originally missing some of the tabs under the API page. I upgraded to 2.1 which gave me the API IP tabs and was able to fill them out, but still getting an error.

My solution was to remove the Admin side of OC from HTTPS as I have a SSL certificate. Once I did that I got no more errors.
The final part of this worked for me. Is there any way of enabling this to work with SSL enabled? And, I have tried all the other API, User, IP address stuff listed above. :)

Does it make any difference that .htpsswd is enabled?

Re: Warning: You do not have permission to access the API! O

Posted: Sat Jan 02, 2016 2:18 pm
by neogeo
in my case i did all suggestion in this thread. https in both config files . add api ......
but when i go to sale to edit order it show me in the top add your ip message . after clic it show me ip successfully added
but no think will happen . api list is empty
finally my problem was corrupted data base table .
this is link for help if u have same problem
http://ocart1.blogspot.ca/2016/01/you-d ... ccess.html

Re: Warning: You do not have permission to access the API! O

Posted: Thu Jan 07, 2016 11:42 pm
by carlbutlr7
mRC wrote:I have a similar issue but I get a pop up saying access denied on any order I view.

but I have a test site and that's working fine. I have done all of the above but same
Hi mRC, I had same problem. mine was because my server was using my ssl on the admin section of the website. try and remove the https:// on both domain.com/admin parts of the config.php file in admin section and replace with http://

That's what solved for me!

Re: Warning: You do not have permission to access the API! O

Posted: Wed Jan 27, 2016 1:08 pm
by jshirey34
I had the same problem and fixed it. Go to Settings>Option and scroll down towards the bottom to API User and make sure that says default. Then go to Users>API and make sure your IP Address is listed under the default setting. It should work without issue then. Hope that helps everybody!

Re: Warning: You do not have permission to access the API! O

Posted: Wed Jan 27, 2016 1:31 pm
by Randem
Some issues are related to an "upgrade", this may help - http://www.randemsystems.com/support/op ... cart-v2-x/

Others may have issues are because of the need for a clean settings table.

Others may have API issues.

Re: Warning: You do not have permission to access the API! O

Posted: Mon Feb 08, 2016 12:51 am
by michael2820
webtiger wrote:go into System > User > API
1 Give Name To Your API Example : " Main IP "
2 Click on Generate API
3 Make it Enable

Click on API Addressees
Click on ADD IP
Copy paste your IP

Click on Save

Then Go to System > Setting > Edit Your main Store > Click on Option
See here : API User
Select Your API USER Which was created in last Stage
For Example Select " main IP "

Regards ;D
thank you very much. Many clicks, but fixed the problem for me v. 2.1.0.2

Re: Warning: You do not have permission to access the API! O

Posted: Wed Mar 02, 2016 12:43 pm
by baihaki
i have a great solution.

Actually the database was missing a file which is oc_api_session
So, you need to export that file on your database.

If you need that file, you have to install the latest version of Opencart. After that, EXPORT that file and IMPORT to your database.

So, its done!
i used on opencart 2.1.0.1

Re: Warning: You do not have permission to access the API! O

Posted: Fri Apr 01, 2016 10:38 am
by Old Yang
go into System > User > API
1 Give Name To Your API Example : " Main IP "
2 Click on Generate API
3 Make it Enable

Click on API Addressees
Click on ADD IP
Copy paste your IP

Click on Save

The right way is go to database update store setting "config_api_id"

set the store id = "your store id" and value the API "setting id"

such as:

UPDATE `setting` SET `value` = '1', `store_id` = '0' WHERE `key` = 'config_api_id'

Re: Warning: You do not have permission to access the API! O

Posted: Fri Apr 01, 2016 10:48 am
by Old Yang
nkolet wrote:I have installed version 2.1.0.1 and have the same issue. I have

Checked the API in options of the store
verified API is enabled
verified admin has all permissions
added my IP address

I am still unable to change the status of an order from pending to shipped. I get the error:

Warning: You do not have permission to access the API!

Anyone have any suggestions? I have looked all over the web.
Check the setting config_api_id

Run Follow step Will be Ok

UPDATE `setting` SET `value` = '1', `store_id` = '0' WHERE `key` = 'config_api_id'

SOLUTION

Posted: Sat Apr 23, 2016 1:50 am
by vousebi
I had the same issue and I found the solution. Hopefully it will be useful.

System >> Setting >> Edit >> Option Tab >> Under Checkout Section :: "API User" >> Please select your API which is set up under System >> Users >> API.

:)

Re: Warning: You do not have permission to access the API! O

Posted: Sun Apr 24, 2016 4:08 am
by Randem
That solution was already given a few times in this thread already...

Re: Warning: You do not have permission to access the API! O

Posted: Sun Apr 24, 2016 6:00 pm
by dxer
I read this entire thread but I am not sure I understand how to fix this. I am using version 2.1.0.2 and have this error too when want to handle orders. As I understand I would need to enter my IP to have option to handle orders, but my IP is not always the same. So should I always add my new IP when want to handle orders ?
How can I disable this IP checking so I coule be allowed to handle orders without this problem ?

Re: Warning: You do not have permission to access the API! O

Posted: Sun Apr 24, 2016 6:14 pm
by Randem

Re: Warning: You do not have permission to access the API! O

Posted: Thu Apr 28, 2016 5:01 pm
by dxer
Randem wrote:API problems - What you need to know

More info...
I am trying to understand this but without success. I am on ADSL internet connection and every 24 hours my IP is changed. So I can't enter specific IP to solve this.
This steps for fixing.....URL-s in config files are valid every one of them, ending with /
First step saying something about IP that store needs to be pointing at. What IP we are talking about, is this IP of the server or what, and where should I enter this IP ?
5th and 6th step I don0t understand either.

Can someone please make this more understandable.
Very much appreciate !

Re: Warning: You do not have permission to access the API! O

Posted: Thu Apr 28, 2016 6:24 pm
by Randem
If your IP changes every 24 hours, the only way to keep from getting the error is to have code that automatically changes your IP in the table. Which of course will be a security concern.

Re: Warning: You do not have permission to access the API! O

Posted: Thu Apr 28, 2016 6:51 pm
by dxer
Randem wrote:If your IP changes every 24 hours, the only way to keep from getting the error is to have code that automatically changes your IP in the table. Which of course will be a security concern.
But I don't understand this feature at all. There is no such restrictions in popular scripts as Wordpress, etc...
How come we can not remove this feature at all. If I can get into admin area, then what is use of this security feature, only not to be able to access orders, but then again if I click Add IP I will get access. Really don't understand purpose of this.