File tree Expand file tree Collapse file tree 1 file changed +25
-0
lines changed
Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Original file line number Diff line number Diff line change @@ -144,6 +144,31 @@ Template.remove_tags('my-template', 'staging')
144144Removing a tag does not delete the build artifact. Other tags pointing to the same build will continue to work.
145145</Warning >
146146
147+ ### List tags
148+
149+ Retrieve all tags for a template. Each tag includes the tag name, the associated build ID, and when the tag was assigned.
150+
151+ <CodeGroup >
152+
153+ ``` typescript JavaScript & TypeScript
154+ import { Template } from ' e2b'
155+
156+ const tags = await Template .getTags (' my-template' )
157+ for (const tag of tags ) {
158+ console .log (` Tag: ${tag .tag }, Build: ${tag .buildId }, Created: ${tag .createdAt } ` )
159+ }
160+ ```
161+
162+ ``` python Python
163+ from e2b import Template
164+
165+ tags = Template.get_tags(' my-template' )
166+ for tag in tags:
167+ print (f " Tag: { tag.tag} , Build: { tag.build_id} , Created: { tag.created_at} " )
168+ ```
169+
170+ </CodeGroup >
171+
147172## Use cases
148173
149174### Semantic versioning
You can’t perform that action at this time.
0 commit comments