{"id":18733214,"url":"https://github.com/jjideenschmiede/gocm","last_synced_at":"2026-05-19T10:06:32.854Z","repository":{"id":118632385,"uuid":"420107483","full_name":"jjideenschmiede/gocm","owner":"jjideenschmiede","description":"Our library to use the cm.com api in golang.","archived":false,"fork":false,"pushed_at":"2021-11-05T16:41:30.000Z","size":11,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-05-19T23:43:27.702Z","etag":null,"topics":["cm","cmdotcom","golang","golang-library"],"latest_commit_sha":null,"homepage":"https://www.cm.com/de/app/docs/","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jjideenschmiede.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-10-22T13:23:24.000Z","updated_at":"2021-11-05T16:40:59.000Z","dependencies_parsed_at":null,"dependency_job_id":"7e6a5951-8cc7-428e-9efe-1825ddb50274","html_url":"https://github.com/jjideenschmiede/gocm","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/jjideenschmiede/gocm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjideenschmiede%2Fgocm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjideenschmiede%2Fgocm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjideenschmiede%2Fgocm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjideenschmiede%2Fgocm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jjideenschmiede","download_url":"https://codeload.github.com/jjideenschmiede/gocm/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjideenschmiede%2Fgocm/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272424978,"owners_count":24932896,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-28T02:00:10.768Z","response_time":74,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cm","cmdotcom","golang","golang-library"],"created_at":"2024-11-07T15:09:02.856Z","updated_at":"2026-05-19T10:06:32.825Z","avatar_url":"https://github.com/jjideenschmiede.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# gocm\n\n[![GitHub go.mod Go version of a Go module](https://img.shields.io/github/go-mod/go-version/jjideenschmiede/gocm.svg)](https://golang.org/) [![Go](https://github.com/jjideenschmiede/gocm/actions/workflows/go.yml/badge.svg)](https://github.com/jjideenschmiede/gocm/actions/workflows/go.yml) [![Go Report Card](https://goreportcard.com/badge/github.com/jjideenschmiede/gocm)](https://goreportcard.com/report/github.com/jjideenschmiede/gocm) [![Go Doc](https://godoc.org/github.com/jjideenschmiede/gocm?status.svg)](https://pkg.go.dev/github.com/jjideenschmiede/gocm)\n\nWith this small library it should be possible to send SMS, WhatsApp \u0026 Co messages via [cm.com](https://www.cm.com/de-de/). And, of course, to make other functions of the API usable.\n\n## Install\n\n```console\ngo get github.com/jjideenschmiede/gocm\n```\n\n## How to use?\n\n### Business Messaging\n\nIn order to send one, or more messages via the Business Messages API, you can use the following function. [Here](https://www.cm.com/app/docs/en/api/business-messaging-api/1.0/index#introduction) you can find an additional description from the manufacturer.\n\nCurrently the following channels can be used: **WhatsApp, Push, RCS, Viber, SMS**\n\n```go\n// Define body\nbody := gocm.MessageBody{\n    Messages: gocm.MessageBodyMessages{\n        Authentication: gocm.MessageBodyAuthentication{\n            Producttoken: \"\",\n        },\n        Msg: []gocm.MessageBodyMsg{},\n    },\n}\n\n// Create a message\nbody.Messages.Msg = append(body.Messages.Msg, gocm.MessageBodyMsg{\n    AllowedChannels: []string{\"SMS\"},\n    From:            \"Test\",\n    To:              []gocm.MessageBodyTo{},\n    Body: gocm.MessageBodyBody{\n        Type:    \"auto\",\n        Content: \"Test message\",\n    },\n})\n\n// Add receiver\nbody.Messages.Msg[0].To = append(body.Messages.Msg[0].To, gocm.MessageBodyTo{\n    Number: \"004941521234567\",\n})\n\n// Send message\nmessage, err := gocm.Message(body)\nif err != nil {\n    fmt.Println(err)\n} else {\n    fmt.Println(message)\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjjideenschmiede%2Fgocm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjjideenschmiede%2Fgocm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjjideenschmiede%2Fgocm/lists"}