Create Linked CB Gallery Media Items

10 months 1 week ago #334199 by krileon
Replied by krileon on topic Create Linked CB Gallery Media Items
I'm not sure I understand the issue. Aren't you creating the activity yourself using API? If that's the case there won't be any media. If you need to act on newly created activity that the user created you'd use the following.

Create
$_PLUGINS->trigger( 'activity_onAfterCreateStreamActivity', array( $stream, $source, $row ) );
Update
$_PLUGINS->trigger( 'activity_onAfterUpdateStreamActivity', array( $stream, $source, $row, $old ) );

var3 in this case is the activity entry. CB Gallery handles its media processing behavior on activity_onBeforeCreateStreamActivity and activity_onBeforeUpdateStreamActivity so should be available in the above 2 triggers.


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 to join the conversation.

10 months 1 week ago #334216 by PaceOnline
Replied by PaceOnline on topic Create Linked CB Gallery Media Items
Sorry let me explain. We are using CB AutoActions to send the activity via request auto actions to Firebase so we use substitutions to set the activity data in the action of the auto action
Attachments:

Please Log in to join the conversation.

10 months 1 week ago #334218 by krileon
Replied by krileon on topic Create Linked CB Gallery Media Items
What trigger are you acting on to do that? The above triggers in my previous reply would ideally be what you should use. Uploaded media should then be in [var3_params_gallery], but it's just going to be an array of media ids so I don't know how useful that will be for you. You may need to consider using a Code action with Method set to PHP and just writing the PHP to gather all the data you need then send that in a cURL call. At some point the no-code options in CB Auto Actions are just not going to be enough for specialized cases.


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 to join the conversation.

6 months 3 weeks ago #335258 by PaceOnline
Replied by PaceOnline on topic Create Linked CB Gallery Media Items
Ok so we got this to work perfectly sending our images to firebase in the gallery however when we try to do the same from the external application we get a 504 gateway timeout; The image is created but the {return $actiondata;} never runs or outputs. This the auto action Firebase - Group - Receive - Media - New we have set up.;

Type: CB Gallery
User: Specific
User ID: [get_owner]
Mode: Item
Method: Create
published: 1
asset: groupjive.group.[get_group]
link: [get_link]
folder:
title: [get_title]
owner:
description: [get_description]
 

Please Log in to join the conversation.

6 months 3 weeks ago #335261 by krileon
Replied by krileon on topic Create Linked CB Gallery Media Items
Manually access the auto action URL supplying whatever GET values you need and make sure it's working before using externally. If it's working with that test then whatever issue you're having isn't with the auto action, but possibly with the data being sent to it or a server problem (e.g. firewall blocking communication).


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 to join the conversation.

6 months 3 weeks ago #335278 by PaceOnline
Replied by PaceOnline on topic Create Linked CB Gallery Media Items
I get the following error:

SyntaxError: JSON.parse: unexpected end of data at line 1 column 1 of the JSON data

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.942 seconds

Facebook Twitter LinkedIn