Skip to content

cloudinary/cloudinary-go

Folders and files

NameName
Last commit message
Last commit date

Latest commit

636439c · Jan 29, 2025
Jan 29, 2025
Jan 29, 2025
Jan 29, 2025
Jun 19, 2023
Jul 23, 2024
Jun 13, 2023
Aug 18, 2024
May 11, 2022
Apr 4, 2021
Apr 2, 2021
Jan 29, 2025
Aug 13, 2021
Jan 5, 2021
Aug 15, 2021
Jan 29, 2025
Aug 13, 2021
Jun 19, 2023
Jun 19, 2023
Jul 23, 2024
Jul 23, 2024

Repository files navigation

Tests Go Report Card PkgGoDev

Cloudinary Go SDK

About

The Cloudinary Go SDK allows you to quickly and easily integrate your application with Cloudinary. Effortlessly optimize, transform, upload and manage your cloud's assets.

Note

This Readme provides basic installation and usage information. For the complete documentation, see the Go SDK Guide.

Table of Contents

Key Features

Version Support

SDK Version Go 1.13 - 1.19 Go 1.20 Go 1.21 Go 1.22 Go 1.23
2.8 & Up ✔️ ✔️ ✔️ ✔️
2.7 ✔️ ✔️ ✔️ ✔️ ✔️
1.x ✔️ ✔️ ✔️ ✔️ ✔️

Installation

go get github.com/cloudinary/cloudinary-go/v2

Usage

Setup

import (
    "github.com/cloudinary/cloudinary-go/v2"
)

cld, _ := cloudinary.New()

Transform and Optimize Assets

image, err := cld.Image("sample.jpg")
if err != nil {...}

image.Transformation = "c_fill,h_150,w_100"

imageURL, err := image.String()

Upload

resp, err := cld.Upload.Upload(ctx, "my_picture.jpg", uploader.UploadParams{})

Security options

Logging

Cloudinary SDK logs errors using standard go log functions.

For details on redefining the logger or adjusting the logging level, see Logging.

Complete SDK Example

See Complete SDK Example.

Contributions

  • Ensure tests run locally
  • Open a PR and ensure Travis tests pass
  • For more information on how to contribute, take a look at the contributing page.

Get Help

If you run into an issue or have a question, you can either:

About Cloudinary

Cloudinary is a powerful media API for websites and mobile apps alike, Cloudinary enables developers to efficiently manage, transform, optimize, and deliver images and videos through multiple CDNs. Ultimately, viewers enjoy responsive and personalized visual-media experiences—irrespective of the viewing device.

Additional Resources

Licence

Released under the MIT license.