@orchesty/connector-mergado
v2.0.0
Published
[](https://www.npmjs.com/package/@orchesty/connector-mergado) [](https://github.com/Orchesty/orchesty-nodejs-co
Downloads
137
Readme
Mergado Connector
An Orchesty connector for Mergado, a platform that helps e-shops automate the flow of product data to search engines and advertising systems such as Google Shopping, Heureka, and Zboží.
Application Type
OAuth 2.0
This connector uses the Mergado OAuth 2.0 authorization code flow. After entering your credentials in Orchesty, you will be redirected to Mergado to authorize access.
| Field | Description |
|---|---|
| client_id | OAuth Client ID from the Mergado Developers Center |
| client_secret | OAuth Client Secret from the Mergado Developers Center |
Components
| Class | Type | Description |
|---|---|---|
| MergadoGetUserConnector | Connector | Fetches details of a Mergado user by ID via GET /users/{id}/ |
| MergadoGetProjectConnector | Connector | Fetches details of a Mergado project by ID via GET /projects/{id}/ |
| MergadoCreateElementConnector | Connector | Creates a new element in a project via POST /projects/{id}/elements |
| MergadoListAppsBatch | Batch | Paginates through all Mergado apps (99 per page) via GET /apps/ |
Setup
Credentials
- Register or log in at the Mergado Developers Center.
- Create a new application to obtain a Client ID and Client Secret.
- Add the Orchesty OAuth callback URL as an allowed redirect URI.
- In Orchesty, open the Mergado application settings, enter the credentials, and complete the OAuth authorization flow.
API Documentation
Mergado Apps API: https://mergado.github.io/docs/
Installation & Usage
Install the package:
npm install @orchesty/connector-mergado @orchesty/nodejs-sdk
# or
pnpm add @orchesty/connector-mergado @orchesty/nodejs-sdkRegister the application and nodes in your Orchesty DI container:
import { container } from '@orchesty/nodejs-sdk';
import { OAuth2Provider } from '@orchesty/nodejs-sdk/dist/lib/Authorization/Provider/OAuth2/OAuth2Provider';
import MergadoApplication from '@orchesty/connector-mergado/dist/MergadoApplication';
import MergadoGetUserConnector from '@orchesty/connector-mergado/dist/Connector/MergadoGetUserConnector';
import MergadoGetProjectConnector from '@orchesty/connector-mergado/dist/Connector/MergadoGetProjectConnector';
import MergadoCreateElementConnector from '@orchesty/connector-mergado/dist/Connector/MergadoCreateElementConnector';
import MergadoListAppsBatch from '@orchesty/connector-mergado/dist/Batch/MergadoListAppsBatch';
const app = new MergadoApplication(container.get(OAuth2Provider));
container.setApplication(app);
container.setNode(new MergadoGetUserConnector(), app);
container.setNode(new MergadoGetProjectConnector(), app);
container.setNode(new MergadoCreateElementConnector(), app);
container.setNode(new MergadoListAppsBatch(), app);License
This connector is released under the Apache License 2.0. See the LICENSE file for the full license text.
Contributing
Contributions are welcome! This connector is part of the open-source Orchesty Node.js Connectors monorepo.
For guidelines on how to create or update connectors — including project setup, coding conventions, and how to write tests — please refer to the Contributing to Connectors guide.
All contributions should include:
- Source code in
src/following the existing connector structure - Tests in
src/**/__tests__/withinput.json,mock.json, andoutput.jsonfixtures - An updated
CHANGELOG.mdentry
