← DEAR Systems + Python integrations

Run Python Code with Python API on New Product from DEAR Systems API

Pipedream makes it easy to connect APIs for Python, DEAR Systems and 1,600+ other apps remarkably fast.

Trigger workflow on
New Product from the DEAR Systems API
Next, do this
Run Python Code with the Python API
No credit card required
Intro to Pipedream
Watch us build a workflow
Watch us build a workflow
7 min
Watch now ➜

Trusted by 750,000+ developers from startups to Fortune 500 companies

Adyen logo
Appcues logo
Bandwidth logo
Checkr logo
ChartMogul logo
Dataminr logo
Gopuff logo
Gorgias logo
LinkedIn logo
Logitech logo
Replicated logo
Rudderstack logo
SAS logo
Scale AI logo
Webflow logo
Warner Bros. logo
Adyen logo
Appcues logo
Bandwidth logo
Checkr logo
ChartMogul logo
Dataminr logo
Gopuff logo
Gorgias logo
LinkedIn logo
Logitech logo
Replicated logo
Rudderstack logo
SAS logo
Scale AI logo
Webflow logo
Warner Bros. logo

Developers Pipedream

Getting Started

This integration creates a workflow with a DEAR Systems trigger and Python action. When you configure and deploy the workflow, it will run on Pipedream's servers 24x7 for free.

  1. Select this integration
  2. Configure the New Product trigger
    1. Connect your DEAR Systems account
    2. Configure timer
    3. Optional- Configure “SKU” Starts With”
    4. Optional- Configure Name Starts With
  3. Configure the Run Python Code action
    1. Connect your Python account
  4. Deploy the workflow
  5. Send a test event to validate your setup
  6. Turn on the trigger

Details

This integration uses pre-built, source-available components from Pipedream's GitHub repo. These components are developed by Pipedream and the community, and verified and maintained by Pipedream.

To contribute an update to an existing component or create a new component, create a PR on GitHub. If you're new to Pipedream component development, you can start with quickstarts for trigger span and action development, and then review the component API reference.

Trigger

Description:Emit new event when a product is created
Version:0.0.4
Key:dear-new-product

DEAR Systems Overview

With the DEAR Systems API, you can build a range of applications that can
automate your business processes. Below are some examples of what you can
build:

  • An application to automatically generate invoices and send them to customers
  • A system to track inventory levels and send alerts when levels are low
  • An app to manage sales orders and send shipping notifications
  • A tool to streamline your purchasing process by integrating with supplier
    systems

Trigger Code

import {
  pick,
  pickBy,
} from "lodash-es";
import constants from "../../common/constants.mjs";
import base from "../common/polling.mjs";

export default {
  ...base,
  name: "New Product",
  key: "dear-new-product",
  type: "source",
  description: "Emit new event when a product is created",
  version: "0.0.4",
  dedupe: "unique",
  props: {
    ...base.props,
    sku: {
      type: "string",
      label: "“SKU” Starts With”",
      description: "Filter products with the *SKU* starting with this value",
      optional: true,
    },
    name: {
      type: "string",
      label: "Name Starts With",
      description: "Filter products with the *Name* starting with this value",
      optional: true,
    },
  },
  methods: {
    ...base.methods,
    defaultParams() {
      const params = pickBy(pick(this, [
        "sku",
        "name",
      ]));
      params.page = 1;
      return params;
    },
    getMetadata(product) {
      const {
        SKU: sku,
        ID: id,
        LastModifiedOn: ts,
        Name: name,
      } = product;

      return {
        id: `${sku}_${id}`,
        ts,
        summary: `New product: ${name}`,
      };
    },
    async pollFunction(params) {
      const data = [];

      while (true) {
        console.log(`Retrieving list of products for page ${params.page}`);
        const { Products: products } = await this.dear.listProducts({
          params: {
            ...params,
            limit: params.limit || constants.PAGE_LIMIT,
          },
        });

        console.log(`Retrieved ${products.length} product(s).`);
        data.push(...products);

        if (products.length < constants.PAGE_LIMIT) {
          console.log("Exausted list of products. Exiting.");
          break;
        }

        console.log("Requesting next page of products.");
        params.page++;
      }

      return data;
    },
  },
};

Trigger Configuration

This component may be configured based on the props defined in the component code. Pipedream automatically prompts for input values in the UI and CLI.
LabelPropTypeDescription
DEAR SystemsdearappThis component uses the DEAR Systems app.
N/Adb$.service.dbThis component uses $.service.db to maintain state between executions.
timer$.interface.timer
“SKU” Starts With”skustring

Filter products with the SKU starting with this value

Name Starts Withnamestring

Filter products with the Name starting with this value

Trigger Authentication

DEAR Systems uses API keys for authentication. When you connect your DEAR Systems account, Pipedream securely stores the keys so you can easily authenticate to DEAR Systems APIs in both code and no-code steps.

To use the API you will need your DEAR Account ID and API Application key. These can be created on the API setup page inside DEAR Inventory application.

About DEAR Systems

DEAR Inventory is a comprehensive inventory control application positioned as a complete back end management system with product planning, cost and development, manufacturing, sales, shipping and payment features.

Action

Description:Write Python and use any of the 350k+ PyPi packages available. Refer to the [Pipedream Python docs](https://pipedream.com/docs/code/python) to learn more.
Version:0.0.2
Key:python-run-python-code

Python Overview

Python API on Pipedream offers developers to build or automate a variety of
tasks from their web and cloud apps. With the Python API, users are able to
create comprehensive and flexible scripts, compose and manage environment
variables, and configure resources to perform a range of functions.

By using Pipedream, you can easily:

  • Create automated workflows that run on a specific schedule
  • Compose workflows across various apps and services
  • React to events in cloud services or form data
  • Automatically create content and notifications
  • Construct classifications and predictions
  • Analyze and react to sentiment, sentiment analysis and sentiment score
  • Connect backends to the frontend with serverless functions
  • Work with files and databases
  • Perform web requests and fetch data
  • Integrate third-party APIs into your apps
  • Orchestrate data processing tasks and pipelines
  • Create powerful application APIs with authentication and authorization
  • Design CI/CD pipelines and Continuous Delivery services
  • Connect databases like MongoDB and MySQL
  • Monitor connections and events
  • Generate alerts and notifications for corresponding events

Action Code

import python from "../../python.app.mjs";

export default {
  name: "Run Python Code",
  version: "0.0.2",
  key: "python-run-python-code",
  description: "Write Python and use any of the 350k+ PyPi packages available. Refer to the [Pipedream Python docs](https://pipedream.com/docs/code/python) to learn more.",
  props: {
    python,
  },
  type: "action",
  methods: {},
  async run({
    steps, $,
  }) {
    // Placeholder action for Python code app
  },
};

Action Configuration

This component may be configured based on the props defined in the component code. Pipedream automatically prompts for input values in the UI.

LabelPropTypeDescription
PythonpythonappThis component uses the Python app.

Action Authentication

The Python API does not require authentication.

About Python

Anything you can do in Python can be done in a Pipedream Workflow. This includes using any of the 350,000+ PyPi packages available in your Python powered workflows.

More Ways to Connect Python + DEAR Systems

Run Python Code with Python API on New Authorized Sale Order from DEAR Systems API
DEAR Systems + Python
 
Try it
Run Python Code with Python API on New Available Stock Level Change from DEAR Systems API
DEAR Systems + Python
 
Try it
Run Python Code with Python API on New Customer Updated from DEAR Systems API
DEAR Systems + Python
 
Try it
Run Python Code with Python API on New Shipment Tracking Number Change from DEAR Systems API
DEAR Systems + Python
 
Try it
Run Python Code with Python API on New Supplier Updated from DEAR Systems API
DEAR Systems + Python
 
Try it
New Authorized Purchase Order from the DEAR Systems API

Emit new event when a purchase order is created and authorized

 
Try it
New Authorized Sale Order from the DEAR Systems API

Emit new event when a sale order is created and authorized

 
Try it
New Authorized Sale Quote from the DEAR Systems API

Emit new event when a sale quote is created and authorized

 
Try it
New Available Stock Level Change from the DEAR Systems API

Emit new event when the available stock level changes. See the documentation

 
Try it
New Customer Updated from the DEAR Systems API

Emit new event when a customer is updated. See the documentation

 
Try it
Run Python Code with the Python API

Write Python and use any of the 350k+ PyPi packages available. Refer to the Pipedream Python docs to learn more.

 
Try it

Explore Other Apps

1
-
12
of
1,600+
apps by most popular

HTTP / Webhook
HTTP / Webhook
Get a unique URL where you can send HTTP or webhook requests
Node
Node
Anything you can do with Node.js, you can do in a Pipedream workflow. This includes using most of npm's 400,000+ packages.
Beta
Python
Python
Anything you can do in Python can be done in a Pipedream Workflow. This includes using any of the 350,000+ PyPi packages available in your Python powered workflows.
Schedule
Schedule
Trigger workflows on an interval or cron schedule.
Beta
Data Stores
Data Stores
Use Pipedream Data Stores to manage state throughout your workflows.
Telegram Bot
Telegram Bot
Telegram is a cloud-based instant messaging and voice over IP service
OpenAI (ChatGPT)
OpenAI (ChatGPT)
OpenAI is an AI research and deployment company with the mission to ensure that artificial general intelligence benefits all of humanity. They are the makers of popular models like ChatGPT, DALL-E, and Whisper.
Google Sheets
Google Sheets
With Google Sheets, you can create, edit, and collaborate wherever you are
Discord
Discord
Use this app to create a Discord source that emits messages from your guild to a Pipedream workflow.
GitHub
GitHub
Where the world builds software. Millions of developers and companies build, ship, and maintain their software on GitHub—the largest and most advanced development platform in the world.
Formatting
Formatting
Pre-built actions to make formatting and manipulating data within your workflows easier.
Slack
Slack
Slack is a channel-based messaging platform. With Slack, people can work together more effectively, connect all their software tools and services, and find the information they need to do their best work — all within a secure, enterprise-grade environment.