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

Support message thread and thread member APIs #34

Merged
merged 6 commits into from
Jun 14, 2024
Merged

Conversation

gffking
Copy link
Contributor

@gffking gffking commented Jun 14, 2024

Read-only APIs for message threads and thread members.

Also adds the beginnings of a CLI tool for testing the API.

cli/.env-default Outdated
@@ -0,0 +1,4 @@
ELATION_BASE_URL=https://app.elationemr.com/api/2.0/
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we have the default vars point to the sandbox env?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, can do.

return err
}

spew.Dump(response)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

spew.Dump call

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's on purpose. I don't want to write formatters for every response type.

@@ -0,0 +1,23 @@
module github.com/authorhealth/go-elation/cli
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this needs to be a separate module

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fair enough. My thinking was by keeping this as a separate module, it avoided making consumers of the client pull in the CLI-specific dependencies like cobra and spew.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's OK for now - maybe revisit when we feel the need to?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably my lack of go-fu, but I'm getting import cycles trying to move this out of the separate package. I'm going to leave this as-is, but if you know a way to resolve this cycles, I'd be happy to refactor.

@gffking gffking merged commit 8d0a0e9 into main Jun 14, 2024
2 checks passed
@gffking gffking deleted the message-thread-apis branch June 14, 2024 17:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants