Code Monkey home page Code Monkey logo

mailchimp-component's Introduction

mailchimp

Mailchimp connector for elastic.io platform

Actions

Subscribe

Upserts information about the subscriber in the list, if subscriber with given e-mail already exists then information will be updated.

This method uses:

PUT /lists/{list_id}/members/{subscriber_hash}

see here for more information

Unsubscribe

This action unsubscribes user from the given list, it uses following HTTP method:

DELETE /lists/${listId}/members/${hash}

see here for more information

mailchimp-component's People

Contributors

denyshld avatar emptyinfinity avatar if0s avatar nazar910 avatar zubairov avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

mailchimp-component's Issues

Action: Add new Subscriber creates subscriber with 'Email type: html' only

Description: Action: Add new Subscriber creates subscriber with 'Email type: html' only, no matter what value was input into 'Email type' field

STR:

  1. Create flow: simple trigger -> mailchimp: Add new Subscriber, input:
    image
  2. Retrieve sample:
Output example { "id": "72e9cb57ec47d709e7d47fd62d19c2c0", "email_address": "[email protected]", "unique_email_id": "4347f4b7c0", "web_id": 332704857, "email_type": "html", "status": "subscribed", "merge_fields": { "FNAME": "", "LNAME": "", "ADDRESS": "", "PHONE": "", "BIRTHDAY": "" }, "stats": { "avg_open_rate": 0, "avg_click_rate": 0 }, "ip_signup": "", "timestamp_signup": "", "ip_opt": "35.234.66.114", "timestamp_opt": "2020-01-13T08:12:46+00:00", "member_rating": 2, "last_changed": "2020-01-13T08:12:46+00:00", "language": "", "vip": false, "email_client": "", "location": { "latitude": 0, "longitude": 0, "gmtoff": 0, "dstoff": 0, "country_code": "", "timezone": "" }, "source": "API - Generic", "tags_count": 0, "tags": [], "list_id": "5b24ff2adc", "_links": [ { "rel": "self", "href": "https://us4.api.mailchimp.com/3.0/lists/5b24ff2adc/members/72e9cb57ec47d709e7d47fd62d19c2c0", "method": "GET", "targetSchema": "https://us4.api.mailchimp.com/schema/3.0/Definitions/Lists/Members/Response.json" }, { "rel": "parent", "href": "https://us4.api.mailchimp.com/3.0/lists/5b24ff2adc/members", "method": "GET", "targetSchema": "https://us4.api.mailchimp.com/schema/3.0/Definitions/Lists/Members/CollectionResponse.json", "schema": "https://us4.api.mailchimp.com/schema/3.0/CollectionLinks/Lists/Members.json" }, { "rel": "update", "href": "https://us4.api.mailchimp.com/3.0/lists/5b24ff2adc/members/72e9cb57ec47d709e7d47fd62d19c2c0", "method": "PATCH", "targetSchema": "https://us4.api.mailchimp.com/schema/3.0/Definitions/Lists/Members/Response.json", "schema": "https://us4.api.mailchimp.com/schema/3.0/Definitions/Lists/Members/PATCH.json" }, { "rel": "upsert", "href": "https://us4.api.mailchimp.com/3.0/lists/5b24ff2adc/members/72e9cb57ec47d709e7d47fd62d19c2c0", "method": "PUT", "targetSchema": "https://us4.api.mailchimp.com/schema/3.0/Definitions/Lists/Members/Response.json", "schema": "https://us4.api.mailchimp.com/schema/3.0/Definitions/Lists/Members/PUT.json" }, { "rel": "delete", "href": "https://us4.api.mailchimp.com/3.0/lists/5b24ff2adc/members/72e9cb57ec47d709e7d47fd62d19c2c0", "method": "DELETE" }, { "rel": "activity", "href": "https://us4.api.mailchimp.com/3.0/lists/5b24ff2adc/members/72e9cb57ec47d709e7d47fd62d19c2c0/activity", "method": "GET", "targetSchema": "https://us4.api.mailchimp.com/schema/3.0/Definitions/Lists/Members/Activity/Response.json" }, { "rel": "goals", "href": "https://us4.api.mailchimp.com/3.0/lists/5b24ff2adc/members/72e9cb57ec47d709e7d47fd62d19c2c0/goals", "method": "GET", "targetSchema": "https://us4.api.mailchimp.com/schema/3.0/Definitions/Lists/Members/Goals/Response.json" }, { "rel": "notes", "href": "https://us4.api.mailchimp.com/3.0/lists/5b24ff2adc/members/72e9cb57ec47d709e7d47fd62d19c2c0/notes", "method": "GET", "targetSchema": "https://us4.api.mailchimp.com/schema/3.0/Definitions/Lists/Members/Notes/CollectionResponse.json" }, { "rel": "events", "href": "https://us4.api.mailchimp.com/3.0/lists/5b24ff2adc/members/72e9cb57ec47d709e7d47fd62d19c2c0/events", "method": "POST", "targetSchema": "https://us4.api.mailchimp.com/schema/3.0/Definitions/Lists/Members/Events/POST.json" }, { "rel": "delete_permanent", "href": "https://us4.api.mailchimp.com/3.0/lists/5b24ff2adc/members/72e9cb57ec47d709e7d47fd62d19c2c0/actions/delete-permanent", "method": "POST" } ] }

AR: FInd in sample: "email_type": "html"
ER:

  1. "email_type": "text"
    OR
  2. in case if "email_type": "text" cannot be set due to mailchimp API behaviour - enum list of available values for email_type should be fixed:
    image

Add credential verification

Description: in this PR will be added stub into code in order to avoid valid credentials verification failure, as it makes imposible to create new creds and use component.

However, we need to implement proper credentials verification mechanism

STR:

  1. Go to Credentials page
  2. Start creating new creds: input valid data
  3. Click on Verify button

AR: Creds are not verified, however on UI it looks like they ware verified
image

logs:

Starting your Docker container ...
[INFO  tini (1)] Spawned child process '/run.sh' with pid '7'
Starting application in apprunner...
Will try to start app at /home/apprunner
node: /usr/lib/libstdc++.so.6: no version information available (required by node)
node: /usr/lib/libstdc++.so.6: no version information available (required by node)
node: /usr/lib/libstdc++.so.6: no version information available (required by node)
node: /usr/lib/libstdc++.so.6: no version information available (required by node)
node: /usr/lib/libstdc++.so.6: no version information available (required by node)
node: /usr/lib/libstdc++.so.6: no version information available (required by node)
node: /usr/lib/libstdc++.so.6: no version information available (required by node)
node: /usr/lib/libstdc++.so.6: no version information available (required by node)
[INFO  tini (1)] Main child exited normally (with status '0')

ER: Creds are actually verified, information regarding successfully verified creds are present in logs and on UI

Output on valid request in Unsubscribe action is empty body: `{}`

Description: It is not obvious that email was unsubscribed when output is - {}

STR:

  1. create flow: step1 - simple trigger
  2. Add step2: mailchimp-component:Add new Subscriber - add new test Subscriber
  3. add step3: mailchimp-component:Unsubscribe - use email of created Subscriber from step2
  4. See output after sample retrieved on step3: {}

AR: Output {}
ER: Need to research API docs to find out what we can provide user with in order to understand that action was run with success.

Some properties are not updated in Add new Subscriber action

STR:

  1. Create new subscription.

  2. Try to update created subscription:
    Input

  3. See that some properties are not updated
    mailchimp UI

AR: Some properties are not updated in Add new Subscriber action and no error message shown

ER:
depends on API:

  • if possible - throw an error message when a property is not updated
  • if API does not provide with this option - specify this behavior in README, because as a user I expect a property to be updated according to specified value if no error thrown

Add output metadata

Description: Add output metadata to all Retrieve Customer action and update in Upsert Customer and Upsert Subscription actions, so Generate Stub Sample button will appear:

image

Rename actions, add action descriptions, update Readme

For component

For each action:
1.
Rename Unsubscribe Action -> Archive a list member
Add action description: Use this action in order to archive a list member.
Add to readme that it use method : DELETE /lists/{list_id}/members/{subscriber_hash} Archive a list member`

Rename Add new Subscriber Action -> Upsert a list member
Add action description: Use this action in order to add or update a list member
Add to readme that it use method : PUT | /lists/{list_id}/members/{subscriber_hash} | Add or update a list member`

Rename Upsert customer action -> Upsert a customer
Add action description: Use this action in order to add or update a customer
Add to readme that it use method: PUT | /ecommerce/stores/{store_id}/customers/{customer_id} | Add or update a customer`

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.