How to use the cloudinary.json.cloud_name function in cloudinary

To help you get started, we’ve selected a few cloudinary examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github silvia-odwyer / Onyx / discordBot.js View on Github external
name: "Original Image",
                                    value: "[Original image found here](https://unsplash.com)"
                                }]
                        }
                    });
                }

            })
            .catch(err => { throw err });
    }

    // CLOUDINARY INTEGRATION
    else if (cmd === "filter") {

        cloudinary.config({
            cloud_name: cloudinary_creds.cloud_name,
            api_key: cloudinary_creds.api_key,
            api_secret: cloudinary_creds.api_secret
        });

        var img_url = msg_array[1];
        console.log(img_url);

        cloudinary.uploader.upload(img_url,
            function (result) {
                console.log(result.eager); msg.channel.send({
                    embed: {
                        color: randomColour,
                        title: `Your Edited Image`,
                        image: {
                            url: result.eager[0].secure_url
                        },