Git Product home page Git Product logo

Comments (6)

 avatar commented on August 12, 2024

Okay - so I tried adding the following fields on my mailing list. Subscription_id and Stripe_id. But I need to find a way to match them with the campaignable additional fields.

I also tried adding a Default Merge Tag Values on Mailchimps side.

from devise_campaignable.

SirRawlins avatar SirRawlins commented on August 12, 2024

from devise_campaignable.

 avatar commented on August 12, 2024

Hi Robert,

Thanks for the response. Let me know if you need any more info to check this out.

Here's my User Model:

  devise :database_authenticatable, :registerable,
         :recoverable, :rememberable, :trackable, :validatable,
         :omniauthable, :campaignable

My devise initializer:

Devise.setup do |config|

  config.campaignable_api_key = 'xxxxxx'
  config.campaignable_list_id = 'xxxxxxx'
  config.campaignable_additional_fields = [:email, :name, :stripe_subscription_id, :stripe_id]

end

Also the callback:

 => {"id"=>"d695463ac7", "status"=>"pending", "total_operations"=>0, "finished_operations"=>0, "errored_operations"=>0, "submitted_at"=>"2017-04-25T17:43:38+00:00", "completed_at"=>"", "response_body_url"=>"", "_links"=>[{"rel"=>"parent", "href"=>"https://us10.api.mailchimp.com/3.0/batches", "method"=>"GET", "targetSchema"=>"https://us10.api.mailchimp.com/schema/3.0/Definitions/Batches/CollectionResponse.json", "schema"=>"https://us10.api.mailchimp.com/schema/3.0/CollectionLinks/Batches.json"}, {"rel"=>"self", "href"=>"https://us10.api.mailchimp.com/3.0/batches/d695463ac7", "method"=>"GET", "targetSchema"=>"https://us10.api.mailchimp.com/schema/3.0/Definitions/Batches/Response.json"}, {"rel"=>"delete", "href"=>"https://us10.api.mailchimp.com/3.0/batches/d695463ac7", "method"=>"DELETE"}]} 

Appreciate the help!

from devise_campaignable.

SirRawlins avatar SirRawlins commented on August 12, 2024

from devise_campaignable.

SirRawlins avatar SirRawlins commented on August 12, 2024

@lauroengineer

I've just released 0.2.3 which includes a fix for this issue.

Seems that after the upgrade from MailChimp API v2 -> v3 we needed to submit the merge_fields in uppercase, so the plugin now up-cases them before sending.

The other thing to be sure of is that you have merge_fields configured on the list in MailChimp which match your attributes.

So if your attributes look like this:

config.campaignable_additional_fields = [:name, :stripe_subscription_id, :stripe_id]

In your MailChimp account, you should have merge_fields configured like this:

NAME, STRIPE_SUBSCRIPTION_ID and STRIPE_ID.

Give this a go and let me know how you get on.

from devise_campaignable.

 avatar commented on August 12, 2024

Sorry about the late reply. Was on vacation.

Thanks for the quick fix. It worked perfectly.

Thanks @SirRawlins!

from devise_campaignable.

Related Issues (7)

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.