Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Recipe to export Epic Comments to CSV #66

Merged

Conversation

semperos
Copy link
Member

This PR also includes some milestone -> objectives renaming.

A customer wrote in asking how to export Epic comments to CSV. After sketching out the code locally, I felt it was worth adding to the api-cookbook recipes.

This also begins to highlight which Python functions should make there way into a Python Shortcut API client library for (re)use by customers and these recipes.

This also removes the separate file with the list of recipe contents,
putting that content directly into the main README for easier
discoverability and maintenance of this important listing of contents.
The useshortcut/exporter project exports Epics, but not their
comments. The exporter is also just a shell script that calls Shortcut
REST API endpoints and saves the JSON to disk, without any further
data manipulation.

This epic-comments recipe leverages the `List Epic Comments` endpoint
in Shortcut's API to fetch the threaded epic comments for an epic (or
all epics in the Shortcut Workspace), which returns a nested JSON
structure for all the epic's top-level and nested comments.

This recipe then flattens the representation, similar to the structure
of Shortcut Story Comments. The resulting CSV of epic comments has a
`parent_id` column that, when populated, indicates the comment that is
the parent of the comment in that row.
@semperos semperos force-pushed the daniel/sc-267254/api-cookbook-recipe-to-create-csv-of-epic branch from 78347ec to d776c31 Compare May 10, 2024 12:23
@semperos semperos requested review from cdemwell and removed request for cdemwell May 10, 2024 15:13
@semperos semperos merged commit 71df792 into main May 10, 2024
2 checks passed
@semperos semperos deleted the daniel/sc-267254/api-cookbook-recipe-to-create-csv-of-epic branch May 10, 2024 15:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants