{"id":19519124,"url":"https://github.com/cmdotcom/cdp-events-sdk-dotnet","last_synced_at":"2026-05-16T17:39:35.928Z","repository":{"id":56253482,"uuid":"313551487","full_name":"cmdotcom/cdp-events-sdk-dotnet","owner":"cmdotcom","description":".NET Standard SDK to send events with CM.com ","archived":false,"fork":false,"pushed_at":"2023-06-12T06:10:09.000Z","size":18,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-10-09T17:42:16.066Z","etag":null,"topics":["cdp","cm","events","netstandard","nuget","sdk"],"latest_commit_sha":null,"homepage":"","language":"C#","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/cmdotcom.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2020-11-17T08:16:47.000Z","updated_at":"2022-06-16T10:43:38.000Z","dependencies_parsed_at":"2025-10-09T17:42:17.146Z","dependency_job_id":"5b6d394c-c529-4e37-a24b-3061301ce144","html_url":"https://github.com/cmdotcom/cdp-events-sdk-dotnet","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/cmdotcom/cdp-events-sdk-dotnet","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmdotcom%2Fcdp-events-sdk-dotnet","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmdotcom%2Fcdp-events-sdk-dotnet/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmdotcom%2Fcdp-events-sdk-dotnet/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmdotcom%2Fcdp-events-sdk-dotnet/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cmdotcom","download_url":"https://codeload.github.com/cmdotcom/cdp-events-sdk-dotnet/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmdotcom%2Fcdp-events-sdk-dotnet/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33112366,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-16T04:41:52.686Z","status":"ssl_error","status_checked_at":"2026-05-16T04:41:52.009Z","response_time":115,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["cdp","cm","events","netstandard","nuget","sdk"],"created_at":"2024-11-11T00:16:27.429Z","updated_at":"2026-05-16T17:39:35.884Z","avatar_url":"https://github.com/cmdotcom.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CDP EventsAPI SDK\n.NET Standard SDK to send events with the CM CDP Events API\n\n## API Documentation\n[https://developers.cm.com/mobile-marketing-cloud/docs/introduction](https://developers.cm.com/mobile-marketing-cloud/docs/introduction)\n\n# Usage\n\n## Instantiate a client\n\n```cs\nHttpClient httpClient = new HttpClient();\nCdpEventsClient eventsClient = new CdpEventsClient(httpClient, myApiKey);\n```\n\n`httpClient` is requested as a parameter, such that you can use a single instance throughout your application, as is highly recommended.\n\n`myApiKey` is your unique api key (or product token) which authorizes you on the CM platform. Always keep this key secret!\n\n`baseUrl` is optional and will be defaulted to https://api.cdp.cm.com when not filled in. Else the requests will be send to the filled in domain.\n\n## Send an event\n\nYou can send events by calling the `AddEvents` method and providing your tenantID (found in the settings page within your Cdp app), a list of events and a cancellation token (optional).\n\nEach event should match a corresponding event type, in order for Cdp to correctly interpret your message. The event type Id's can be found in the sources page in your Cdp app.\n\n```cs\nApiEvent[] events = new[]\n{\n\tnew ApiEvent\n\t{\n\t\tEventTypeId = registrationEventTypeId,\n\t\tEvent = new Registration\n\t\t{\n\t\t\tEmail = userEmailAddress,\n\t\t\tMessage = \"It's a great day\",\n\t\t\tSubject = \"The sun is shining and so are you.\"\n\t\t}\n\t},\n\tnew ApiEvent\n\t{\n\t\tEventTypeId = crmUpdateEventTypeId,\n\t\tEvent = new CrmUpdate\n\t\t{\n\t\t\tEmail = userEmailAddress,\n\t\t\tPhoneNumber = userPhoneNumber\n\t\t}\n\t}\n};\nawait eventsClient.AddEvents(myTenantId, events).ConfigureAwait(false);\n```\n\n## Send an anonymous event\n\nSome event types can be whitelisted, so that no authentication is needed for sending the events. This may be useful for sending tracking data from websites. When calling the `AddAnonymousEvents` method, your ApiKey will not be validated, only if the event type is whitelisted for your account.\n\n```cs\nApiEvent[] events = new[]\n{\n\tnew ApiEvent\n\t{\n\t\tEventTypeId = memberPageVisitEventTypeId,\n\t\tEvent = new PageVisit\n\t\t{\n\t\t\tEmail = userEmailAddress,\n\t\t\tPage = currentPageUrl\n\t\t}\n\t}\n};\nawait eventsClient.AddAnonymousEvents(myTenantId, events).ConfigureAwait(false);\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcmdotcom%2Fcdp-events-sdk-dotnet","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcmdotcom%2Fcdp-events-sdk-dotnet","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcmdotcom%2Fcdp-events-sdk-dotnet/lists"}