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

New Source: Presta Shop #2980

Closed
sherifnada opened this issue Apr 20, 2021 · 4 comments · Fixed by #4465
Closed

New Source: Presta Shop #2980

sherifnada opened this issue Apr 20, 2021 · 4 comments · Fixed by #4465

Comments

@sherifnada
Copy link
Contributor

sherifnada commented Apr 20, 2021

Tell us about the new integration you’d like to have

popular open source shopfront platform https://github.com/PrestaShop/PrestaShop/

Describe the context around this new integration

  • Which team in your company wants this integration, what for? This helps us understand the use case.
  • How often do you want to run syncs?
  • If this is an API source connector, which entities/endpoints do you need supported?

Describe the alternative you are considering or using

What are you considering doing if you don’t have this integration through Airbyte?

┆Issue is synchronized with this Asana task by Unito

@vitaliizazmic
Copy link
Contributor

vitaliizazmic commented Jun 14, 2021

Integration Vetting

PrestaShop is an Open Source e-commerce web application, which is written in PHP.

Server configuration

The first stable version of PrestaShop 1.7, 1.7.0.0, was released on November 7th, 2016. Further updates have been released since then.

To install the latest PrestaShop 1.7, we need a web server running PHP 7.1+ and any flavor of MySQL 5.0+ (MySQL, MariaDB, Percona Server, etc.). Versions between 1.7.0 and 1.7.6 work with PHP 5.6+.

PrestaShop enables merchants to give third-party tools access to their shop’s database through a CRUD API, otherwise called a web service.

By default, the webservice feature is disabled on PrestaShop and needs to be switched on before the first use.

Webhook-based? (no/partially/yes)

No

Available authentication modes (API key/Oauth/other)

Access key

Connecting to the data source

The PrestaShop web service uses the REST architecture

Testing access to the Webservice

Creating an account

Instance deployment is required.

How to populate the account with data?

Fake data can be populated while installing PrestaShop instance. But it also can be done entirely through the API or through the UI.

Available streams for sync

Resource schemas

The Webservices can output JSON resource schemas

By default simple list that returns the IDs of the resources is received. For returning all fields use display=full parameter.

Available resources

Do any streams support incremental sync?

We can filter the expected result with the filter parameter

Some resources have date_add and date_upd, but they are optional.

Preparation scope & blockers

Instance deployment is required.

Other information/blockers

Singer Tap isn't available.

@keu
Copy link
Contributor

keu commented Jun 14, 2021

@vitaliizazmic
Copy link
Contributor

vitaliizazmic commented Jun 15, 2021

Are the account test credentials available in Lastpass?

Account test credentials doesn't available in Lastpass. To work with Source we can deploy instance locally using Docker image.

Task breakdown

  • Populate source with data - fake data can be populated while installing PrestaShop instance.
  • Installing PrestaShop instance. Create access key - 1-2h
  • Create source scaffolding and populate schemas folder - API returns schemas for each resources but in XML format. - 5-6h
  • Implement spec, check, and discover - 1-2h
  • Implement Read
    • Create API base abstract class
    • Create Base stream abstract classes - 6-8h
    • Implement base abstract classes for incremental streams 5-7h
  • Handle rate limiting - 3-4h
  • Implement standard tests - 2-3h

@sherifnada
Copy link
Contributor Author

@vitaliizazmic just seeing this now -- can we support just a subset of the available streams to start with? Just want to make sure we keep the scope of the PR manageable and add more endpoints as users request them. Streams that seem like the most valuable:

  • Contacts
  • Customers
  • Carts
  • Employees
  • Orders
  • Order invoices
  • Order histories
  • Order Details
  • Products
  • Shops
  • Suppliers
  • Stocks
  • Stock Movements
  • Taxes

If you have already implemented others we can keep those (no need to throw them away) but hopefully this can help focus the scope

vitaliizazmic added a commit that referenced this issue Jul 1, 2021
vitaliizazmic added a commit that referenced this issue Jul 2, 2021
@sherifnada sherifnada added the priority/medium Medium priority label Jul 9, 2021
@keu keu self-assigned this Jul 20, 2021
@keu keu closed this as completed in #4465 Jul 27, 2021
keu pushed a commit that referenced this issue Jul 27, 2021
* Source PrestaShop #2980 - init commit

* Source PrestaShop #2980 - schemas

* Source PrestaShop #2980 - full refresh sync

* Source PrestaShop #2980 - incremental sync, acceptance tests

* Source PrestaShop #2980 - incremental acceptance tests

* Source PrestaShop #2980 - incremental acceptance tests (remove configurations from incremental)

* Source PrestaShop #2980 - change Configurations stream to full refresh

* Source PrestaShop #2980 - docs

* format

* fix schemas, fill streams with data

* fix tests and future_state

* rename presta-shop -> prestashop

* fix mounting volumes inside a nested container

* special handle for NULL dates (MySQL)

* fix build URL

* fix URL and polishing

* fix header

* fix template

* format, update pre-commit to execute in the right order

* fix scaffolding

* bump and changelog for SAT

* register as the default source

* fix test timeout

Co-authored-by: Eugene Kulak <kulak.eugene@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants