{"id":19622203,"url":"https://github.com/commercetools/project-config-replication","last_synced_at":"2026-03-19T10:50:20.160Z","repository":{"id":33960778,"uuid":"144874411","full_name":"commercetools/project-config-replication","owner":"commercetools","description":"An interface to propagating changes across commercetools projects","archived":false,"fork":false,"pushed_at":"2023-04-29T03:54:06.000Z","size":504,"stargazers_count":2,"open_issues_count":8,"forks_count":0,"subscribers_count":61,"default_branch":"master","last_synced_at":"2025-02-25T14:56:09.112Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/commercetools.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2018-08-15T16:02:07.000Z","updated_at":"2024-09-22T16:34:28.000Z","dependencies_parsed_at":"2024-11-11T11:32:15.394Z","dependency_job_id":"9a99733d-e6ee-4f4a-929a-9c1c95c1de8e","html_url":"https://github.com/commercetools/project-config-replication","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/commercetools%2Fproject-config-replication","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/commercetools%2Fproject-config-replication/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/commercetools%2Fproject-config-replication/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/commercetools%2Fproject-config-replication/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/commercetools","download_url":"https://codeload.github.com/commercetools/project-config-replication/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240917722,"owners_count":19878308,"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","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":"2024-11-11T11:26:35.150Z","updated_at":"2026-03-19T10:50:20.121Z","avatar_url":"https://github.com/commercetools.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"ct-project-config-replication\n====\n\nThis tool provides a scriptable interface to applying changes between commercetools projects.\nGiven a directory of files each with a change (referred to as a migration), this tool will apply them to the configured project.\n\nWarning\n====\nThis project is in its infancy and should not be considered production ready!\n\n\nInstallation\n----\n\nInstall this project's dependencies by running `npm install`.  Run `npm build` to build this project.\n\nHow to write a migration\n---\n\nA migration is a JSON file with a few fields defined.  All migrations should have top-level \"type\", \"action\" and \"key\" fields defined.  These refer to the resource type (product, productType, etc), the action to apply (\"create\", \"update\", \"delete\"), and the key to locate the resource on commercetools.  Additionally migrations with the type \"create\" must have a top-level field \"payload\", and migrations with type \"update\" must have a top-level field \"actions\".  The payload defines the resource draft and the actions is an array of update actions to apply to the resource.  There are examples included in the examples directory.  Each migration's filename must begin with a 5 digit number, 00000 to 99999 indicating the order in which to apply the migrations.  Also the filename should be structured like the following: 00000-action-description.json.  Lower-numbered migrations are run first.\n\nConfiguration\n---\nThere are several optional flags to configure this program, alternatively you may use environment variables.  See the output of `node dist/index.js --help` below for more information.\n\n```\n  Usage: index [options] \u003cmigrationsDirectory\u003e\n\n  Options:\n\n    -v, --version                      output the version number\n    -c, --clientId [clientId]          Client ID\n    -s, --clientSecret [clientSecret]  Client Secret\n    -p, --projectKey [projectKey]      Project Key\n    -a, --authUrl [authUrl]            Auth URL (default: https://auth.commercetools.co)\n    -i, --apiUrl [apiUrl]              API URL (default: https://api.commercetools.co)\n    -t, --concurrency [concurrency]    Concurrency (default: 10)\n    -d, --dryRun                       Dry Run\n    -h, --help                         output usage information\n\n  Environment Variables:\n\n    CLIENT_ID\n    CLIENT_SECRET\n    PROJECT_KEY\n    AUTH_URL\n    API_URL\n```\n\nRunning\n---\nRun the program via `node dist/index.js [options] \u003cpathToMigrationDirectory\u003e`\n\nMore Info\n---\n\n* This script will create a custom object \"ct-migrations/ct-last-applied\" in your commerctools project to keep track of the last applied migration.  This script relies on this custom object, alter it at your own risk.\n* In the future this might be available to install via npm, to ease integration into a CD pipeline.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcommercetools%2Fproject-config-replication","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcommercetools%2Fproject-config-replication","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcommercetools%2Fproject-config-replication/lists"}