Jump to content

API Key


sharifnaim

Recommended Posts

Greetings,

 

Hope you all are fine well.

This is my first topic, so please dont hate me.

 

I was given an API key from a company I am using to purchase my products for the past 20 years.

The API key is to help me uploading their products to my new website automatically.

 

The problem is that I cant find where to enter the key anywhere in the site.

Can anyone help me with that please.

 

The PrestaShop is the best I found so far and I dont want to change it to something else because of this.

 

Your kind help is more than appreciated.

 

Kind regards,

Sharif

Link to comment
Share on other sites

Hi Sharif

 

Welcome to the forum and hope you find all solutions you need.

 

I see that having just API key can be confusing, but will try to give you some options.

If they give you API key there must be some documentation how to use that key. Try to explore

their website, or just ask for some guidelines. And check if they maybe by chance have solution for commerce

in general, but ideally for PrestaShop. If you want you can share company name. 

 

If not they with API key you probably have access to their product and a way to download list of products

in CSV or Excel file format. With that file you could import product your self with CSV import option PrestaShop have

http://doc.prestashop.com/display/PS16/CSV+Import+Parameters . But if you want to do that auto and every day for

that you probably will have to use some of paid module, think there are few on official marketplace like this one

https://addons.prestashop.com/en/data-import-export/20579-import-update-bulk-product-from-any-csv-excel-file-pro.html

(note this is just example, have not used this module) or there is desktop software called Store commander that some people

are using that have that as one of option.

 

Regards

Laza

Link to comment
Share on other sites

Dear Laza,

 

Many thanks for your kind reply which is informative.

 

As a matter of fact, they sent me a spreadsheet with the products.

However, when I tried to upload it to the site it didnt like it as it only uses CSV.

Sadly enough, I tried to convert it to the site requirements but all attempts failed.

 

I couldnt find a way to convert the spreadsheet automatically.

 

Once again, many thanks for your kind reply.

Hopefully I will figure something out in my old age.

 

Kind regatds,

Sharif

Link to comment
Share on other sites

In lot of cases if you have some API they do provide xls mainly but also CSV files also.

So maybe try and ask, that could be available.

 

 

And if you can open spreadsheet there should be option to export or just save as CSV

with options to choose field separator. I advice to take first just few rows for test and 

when importing into PrestaShop do save column settings after you match them with 

fields in CSV file.

 

Wish you luck with import.

 

Kind regards

 

Laza

Link to comment
Share on other sites

Hi Laza,

 

Many thanks for your kind reply and efforts making things easy.

I managed to find this easy way to convert xls to CSV

https://www.addictivetips.com/windows-tips/convert-xls-to-csv/

 

The only problem I am facing now whenever I try to upload the CSV file I got these errors as shown in the attachment

Also, how to merge the API key and the CSV file together, or to upload only CSV and ignore the API key.

 

So confusing loooool

 

post-1438326-0-12158900-1504865367_thumb.png

Link to comment
Share on other sites

Nice some progress :)

 

Check your CSV file in Notepad or any other text editor, and compare to one from documentation link I posted.

 

 

 

1;"Test";"1,2,3";130;1;75;0;"PROD-TEST";"0.500";10;"'Tis a short desc.";"This is a long description.";"

 

see, it should have ; to separate fields and also have " " around all fields except numbers. Notice third field "1,2,3"  that is one field 

with multiple values separated by ,   

 

Also easier option would be before import to have , as field separator and some other character that separate multiple values in single field.

And judging from your screenshot you do have , so try that in Import configuration.

 

To automate process, well you will need custom solution. I think there are no free modules for that but you

search a bit. And for paid modules check https://addons.prestashop.com/en/451-data-import-export for some general solution

to imports CSV files but do ask developers about your case. Also that Store Commander for PrestaShop have 30 days trial.

 

Some of those solutions  may have already option to access product providers. For that you will use API key. Then those solutions

have access to file, and may import it in xls format, so no need to transform to CSV. And if not included some custom code would be

required for getting your products feed from supplier with API key.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...