Gallery hook configuration

We do not store the images of our partners on our server side. If someone uploads an image to our gallery, we immediately upload it to our partner’s server. It means that there has to be an upload hook to be given on our side. There are two ways to configure it. The first option happens on the dashboard, but you can do it programmatically through our API as well.

Basic skinning of EDMdesigner API

On the screenshot above you can see the part of our dashboard on which you can configure the hooks and some other things as well. The two most important ones are the upload and the delete hooks. Without them, the gallery cannot be functional. If you want to implement copy functionality, then you should set up a copy hook as well. There are three other things that you can set up here. The first two are messages that will appear if someone reached the limit what you can set up in their groups, so I will talk about those in a separate post. The last option is that you can forbid your users to set urls of the images from anywhere. This way you can force your users to use only those pictures which are hosted by you. It can be useful if you don’t want your email to be spammy. (If there are lot of different domains referenced in your email, that is generally bad for your spam score.)

You might want to configure your gallery programatically. It is useful when you create a system or plugin or whatever that you want to set up on different domains. If you include gallery setup in your install script, that will save you a lot of time. You can do it via our API. You need to generate an admin token on your server side and you can call the gallery config routes.

Gallery hook security

When we send requests to the hooks that you provided, we send a userId, a hash and a timestamp. The hash is the md5 hash of the concatenation of your magic word and the timestamp we send. This way you can make sure that we sent the request and you can send back 403 if someone is trying with some nasty things.

Basic skinning

There is one other very cool feature on the dashboard. We call it “basic skinning” and you can find it under the skinning menu item. Basically you can customize the colors of the editor itself per API key. You just have to pick seven different colors, which will define the color scheme associated to that API key. This feature is not yet available via our API, but we are planning to introduce it as well, since some of our partners have hundreds of API keys and it’s a pain if they have to change the colors manually for every API key.

How to configure EDMdesigner's gallery on API Dashboard

That’s all folks, by now you should be able to integrate EDMdesigner into your system with functional gallery and the colors of the editor should be aligned with the color set of your application. I hope you find these posts useful. If you have any questions, please ask. If you want me to write a post about a certain topic, please let me know.

Author
Gyula Németh

Gyula Németh

Co-founder & CTO @ EDMdesigner.com

  • 16 Command Examples to Send Email From The Linux Command Line 16 Command Examples to Send Email From The Linux Command Line

    In this post you'll learn how to send emails from the Linux command line. I'll show the most often used commands, SMTP configuration and terminal options.

    Read more
  • How to Create Responsive Email Designs with React Native How to Create Responsive Email Designs with React Native

    Responsive email coding is complex. Are you native in React Native? Abstract away email HTML & CSS into components with react-html-email or mjml frameworks.

    Read more
  • Using PHP for Sending HTML Emails with Mailgun, Sendgrid & Amazon SES Using PHP for Sending HTML Emails with Mailgun, Sendgrid & Amazon SES

    Ever wondered how to use PHP for sending HTML email templates with Mailgun, Sendgrid and Amazon SES? Read on for step-by-step coding advice.

    Read more