# Codefresh programmatically add shared config to pipeline

**URL:** <https://community.codefresh.io/t/codefresh-programmatically-add-shared-config-to-pipeline/494>\
**Category:** Pipeline Workflows\
**Created:** [January 26, 2021, 4:36pm UTC](https://community.codefresh.io/t/codefresh-programmatically-add-shared-config-to-pipeline/494 "2021-01-26T16:36:23Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![guycushion](https://sea1.discourse-cdn.com/flex019/user_avatar/community.codefresh.io/guycushion/32/326_2.png) [@guycushion](https://community.codefresh.io/u/guycushion)\
**Post date:** [January 26, 2021, 4:36pm UTC](https://community.codefresh.io/t/codefresh-programmatically-add-shared-config-to-pipeline/494/1 "2021-01-26T16:36:23Z")

</div>

as the title says, is there a way to add shared config variables to a pipeline that has been created using the cli via a yml file without using the GUI?

---

<div class="post-metadata">

**Author:** ![Kostis](https://sea1.discourse-cdn.com/flex019/user_avatar/community.codefresh.io/kostis/32/391_2.png) [@Kostis](https://community.codefresh.io/u/Kostis)\
**Post date:** [January 27, 2021, 7:50am UTC](https://community.codefresh.io/t/codefresh-programmatically-add-shared-config-to-pipeline/494/2 "2021-01-27T07:50:53Z")

</div>

Hello and welcome to the Codefresh community!

Yes it is possible. You can just use the codefresh cli to add/edit entries under the “contexts” fields  
in the pipeline definition

[Codefresh API · Codefresh | Docs](https://codefresh.io/docs/docs/integrations/codefresh-api/#spec-fields) (see the `contexts` field description)

For editing shared configuration entries with the CLI, this is also possible [Codefresh CLI Documentation](https://codefresh-io.github.io/cli/contexts/create-context/)

Let me know if you need more clarifications.
