Skip to Content Skip to Menu

🎃 Happy Halloween! Treat yourself with an awesome discount on memberships! Get 20% off now with code SPOOKY-2024!

Plug-In API documentation?

  • petekuhn
  • petekuhn
  • OFFLINE
  • Posts: 239
  • Thanks: 34
  • Karma: 0
8 years 11 months ago #273230 by petekuhn
Plug-In API documentation? was created by petekuhn
Is there current documentation for developing Plug-Ins? I couldn't find any.

I want to do something every time a user activates a subscription. I'm thinking it might be easier (and less coupled with CB changes) to scan the database every day and trigger it off new subscriptions.

Anyway, I know you don't deal with customization, but I was just looking for whatever info is available on plug-in development so I could figure out the best way to go. TIA.

Please Log in or Create an account to join the conversation.

  • nant
  • nant
  • OFFLINE
  • Posts: 12339
  • Thanks: 1467
  • Karma: 877
8 years 11 months ago #273240 by nant
Replied by nant on topic Plug-In API documentation?

petekuhn wrote: Is there current documentation for developing Plug-Ins? I couldn't find any.

I want to do something every time a user activates a subscription. I'm thinking it might be easier (and less coupled with CB changes) to scan the database every day and trigger it off new subscriptions.

Anyway, I know you don't deal with customization, but I was just looking for whatever info is available on plug-in development so I could figure out the best way to go. TIA.


Depending on what you want to do you might be better off just using CB Auto Actions as it does recognize all CBSubs related triggers.

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48466
  • Thanks: 8280
  • Karma: 1443
8 years 11 months ago #273300 by krileon
Replied by krileon on topic Plug-In API documentation?
You can use the below to trigger any action in CB Auto Actions on subscription state changes. The majority of our CBSubs integrations for example are simple plugin usages of this trigger.

Plan Active
Triggers: onCPayUserStateChange
User: Automatic
Access: Everybody
Conditional 1: [var3] Equal To PLAN_ID_HERE
Conditional 2: [var2] Equal To A

Plan Expired
Triggers: onCPayUserStateChange
User: Automatic
Access: Everybody
Conditional 1: [var3] Equal To PLAN_ID_HERE
Conditional 2: [var2] Equal To X


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

  • petekuhn
  • petekuhn
  • OFFLINE
  • Posts: 239
  • Thanks: 34
  • Karma: 0
8 years 11 months ago #273348 by petekuhn
Replied by petekuhn on topic Plug-In API documentation?
Thanks. I watched several of Nick A's videos on Auto Actions, and I think I can use them with your trigger and the query action to log the state change for later digestion by a cron task.

I did not find any documentation on the query action or on the variables used in the trigger. Can you point me to this?

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48466
  • Thanks: 8280
  • Karma: 1443
8 years 11 months ago #273376 by krileon
Replied by krileon on topic Plug-In API documentation?
The parameters in almost all cases are self explanatory with descriptions further describing what values they expect. In the case of the query action the "Query" parameter is where you'd specify your database query. The below video uses a query action in its usecase.



Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum