{"id":30312704,"url":"https://github.com/mparticle/data-planning-snippets","last_synced_at":"2025-08-17T17:14:20.859Z","repository":{"id":40794475,"uuid":"238014559","full_name":"mParticle/data-planning-snippets","owner":"mParticle","description":null,"archived":false,"fork":false,"pushed_at":"2023-06-26T16:48:28.000Z","size":13812,"stargazers_count":2,"open_issues_count":16,"forks_count":0,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-08-08T19:54:10.281Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mParticle.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-02-03T16:51:27.000Z","updated_at":"2023-08-20T22:59:37.000Z","dependencies_parsed_at":"2023-02-18T03:46:09.053Z","dependency_job_id":null,"html_url":"https://github.com/mParticle/data-planning-snippets","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/mParticle/data-planning-snippets","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mParticle%2Fdata-planning-snippets","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mParticle%2Fdata-planning-snippets/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mParticle%2Fdata-planning-snippets/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mParticle%2Fdata-planning-snippets/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mParticle","download_url":"https://codeload.github.com/mParticle/data-planning-snippets/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mParticle%2Fdata-planning-snippets/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270877420,"owners_count":24661138,"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-17T02:00:09.016Z","response_time":129,"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":[],"created_at":"2025-08-17T17:14:19.735Z","updated_at":"2025-08-17T17:14:20.843Z","avatar_url":"https://github.com/mParticle.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# mParticle Data Planning Snippets SDK\n\n\u003cimg src=\"https://static.mparticle.com/sdk/mp_logo_black.svg\" width=\"280\"\u003e\u003cbr\u003e\n\n[![npm](https://img.shields.io/npm/v/@mparticle/data-planning-snippets.svg?maxAge=2592000)](https://www.npmjs.com/package/@mparticle/data-planning-snippets)\n\nHello! This is the public repo of the mParticle Data Planning Snippet SDK. We've built the mParticle platform to take a new approach to web and mobile app data and the platform has grown to support 200+ services and SDKs, including developer tools, analytics, attribution, messaging, and advertising services. mParticle is designed to serve as the connector between all of these services - check out [our site](http://mparticle.com), or hit us at developers@mparticle.com to learn more.\n\n:arrow_right: [**Check out the demo here**](https://mparticle.github.io/data-planning-snippets/)\n\n## Documentation\n\nFully detailed documentation and other information about mParticle web SDK can be found at our doc site\n\n-   [Core mParticle SDK](https://docs.mparticle.com/developers/sdk/web/getting-started)\n\nWhat is Data Planning? Data Planning is part of the new Data Master feature for the mParticle SDK. Check out this section of the doc site to learn more.\n\n-   [Data Master mParticle SDK](https://docs.mparticle.com/guides/data-master/)\n\n# Overview\n\nThe main purpose of this project is to create example code for clients based off of their data plans.\n\nThis project allows the you to input a DataPlanPoint and recieve executable code.\n\n# Getting Started\n\n## Importing Data Planning Snippets\n\n`$ npm install @mparticle/data-planning-snippets`\n\nTo use this within your project:\n\n```typescript\nimport { MPSnippets } from '@mparticle/data-planning-snippets';\n```\n\n## Generate a Snippet\n\nTo get a `DataPlanPoint` you'll first need to fetch your DataPlan using the [Data-Planning-Node Library](https://www.npmjs.com/package/@mparticle/data-planning-node) or the [MParticle CLI](https://www.npmjs.com/package/@mparticle/cli)\n\n```typescript\nimport { MPSnippets } from '@mparticle/data-planning-snippets';\n\n// Generate a Swift snippet\nconst exampleCode = MPSnippets.createSnippet(dataPlanPoint, Language.Swift);\n\n// Generate a Objective C snippet\nconst exampleCode = MPSnippets.createSnippet(\n    dataPlanPoint,\n    Language.ObjectiveC\n);\n```\n\n# Contribution Guidelines\n\nAt mParticle, we are proud of our code and like to keep things open source. If you'd like to contribute, simply fork this repo, push any code changes to your fork, and submit a Pull Request against the `master` branch of mParticle/data-planning-snippets.\n\n## Running the Tests\n\nPrior to running the tests please install all dev dependencies via an `npm install`, and build the mParticle.js file as well as the test file by running `npm run build`:\n\n```bash\n$ npm install\n$ npm run build\n$ npm test\n```\n\nThe test script will run all tests using Mocha as unit tests.\n\n## Development Notes\n\nThis package comes with the NPM package [pre-commit](https://www.npmjs.com/package/pre-commit), which will run [GTS](https://github.com/google/gts) when you try to commit.\n\n## Support\n\n\u003csupport@mparticle.com\u003e\n\n## License\n\nThe mParticle Web Media SDK is available under the [Apache License, Version 2.0](http://www.apache.org/licenses/LICENSE-2.0). See the LICENSE file for more info.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmparticle%2Fdata-planning-snippets","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmparticle%2Fdata-planning-snippets","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmparticle%2Fdata-planning-snippets/lists"}