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

chat-headless: add support for session reinitialization #59

Merged
merged 7 commits into from
Oct 2, 2024

Conversation

popestr
Copy link
Collaborator

@popestr popestr commented Sep 25, 2024

Adds session state management for the credentials returned by the underlying agent client, such that on agent client initialization, the returned credentials are saved in session storage. When chat-headless is reloaded and getNextMessage is called, the session in the agent client is reinitialized.

Session credentials are cleared any time the client is reset.

TEST=manual,auto

Wrote new unit tests, saw them pass.

Ran local test app with a Zendesk client, saw conversation persisted across page refreshes.

Adds session state management for the credentials returned by the underlying
agent client, such that on agent client initialization, the returned credentials
are saved in session storage. When chat-headless is reloaded and getNextMessage
is called, the session in the agent client is reinitialized.

Session credentials are cleared any time the client is reset.

TEST=manual,auto

Wrote new unit tests, saw them pass.

Ran local test app with a Zendesk client, saw conversation persisted
across page refreshes.
@popestr popestr requested a review from a team as a code owner September 25, 2024 19:37
@popestr popestr merged commit ff7d174 into main Oct 2, 2024
8 checks passed
@popestr popestr deleted the dev/reinitialize-session branch October 2, 2024 19:24
yen-tt added a commit that referenced this pull request Oct 22, 2024
previous [PR](#59) updated headless dep in chat-headless-react package.json to v.0.12.0 but didn't publish a new version for chat-headless-react.
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