Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Cloud device api #1568

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

Open
gcatanese wants to merge 26 commits into main
base: main
Choose a base branch
Loading
from cloud-device-api
Open

Cloud device api #1568

gcatanese wants to merge 26 commits into main from cloud-device-api

Conversation

@gcatanese
Copy link
Contributor

@gcatanese gcatanese commented Oct 2, 2025

This PR introduces the first implementation of the Cloud device API:

  • create new service to support 4 endpoints
    POST https://<Base-URL>/v1/merchants/{merchantAccount}/devices/{deviceId}/sync
    POSThttps://<Base-URL>/v1/merchants/{merchantAccount}/devices/{deviceId}/async
    GEThttps://<Base-URL>/v1/merchants/{merchantAccount}/devices/{deviceId}/status
    GEThttps://<Base-URL>/v1/merchants/{merchantAccount}/connectedDevices
  • add support for encryption of request for /sync and async endpoints
  • add support for decryption of encrypted event notifications and async responses
  • add tests
  • improve README

@gcatanese gcatanese added the Feature Indicates a new feature addition label Oct 2, 2025
@gcatanese gcatanese requested a review from a team as a code owner October 2, 2025 15:26
Copy link
Contributor

Summary of Changes

Hello @gcatanese, I'm Gemini Code Assist1 ! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request delivers the foundational implementation of the Cloud Device API, a significant step towards modernizing in-person payment integrations. It provides a comprehensive set of endpoints for managing and communicating with payment devices, supporting both synchronous and asynchronous operations. A key focus is on security, with built-in encryption and decryption for sensitive transaction data. The accompanying documentation has been thoroughly revised to guide developers through the new API's capabilities and best practices.

Highlights

  • New Cloud Device API: Introduced the first implementation of the Cloud Device API, enabling new functionalities for in-person payments.
  • New Endpoints: Added support for four new endpoints: /sync, /async, /status, and /connectedDevices for managing and interacting with cloud devices.
  • Encryption Support: Implemented encryption for /sync and /async requests and decryption for encrypted event notifications and asynchronous responses to enhance security.
  • Documentation Updates: The README has been improved with a dedicated section for the Cloud Device API, including usage examples, and detailed documentation has been moved to new markdown files (doc/CloudDeviceApi.md and doc/TerminalApi.md).
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces a significant new feature: the Cloud Device API. It adds a comprehensive set of models under the com.adyen.model.clouddevice package, a new CloudDeviceApi service to interact with the API endpoints, and detailed documentation in doc/CloudDeviceApi.md and doc/TerminalApi.md. The implementation also includes support for encrypted communication and helper classes for parsing API responses. The main README.md has been refactored to improve structure and readability.

The review focuses on the new code and documentation. While the overall implementation is solid, a few issues have been identified:

  • An incorrect code example in the documentation for handling asynchronous responses.
  • A minor typo in a documentation header.
  • Inconsistent use of JSON serialization libraries within the new models.
  • Inefficient encoding in a data-to-Base64 conversion method.
  • Use of a generic RuntimeException where a more specific one would be appropriate.

These are relatively minor points in a large and well-structured contribution. Addressing them will improve the consistency, correctness, and usability of the new API client.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

1 more reviewer

@gemini-code-assist gemini-code-assist[bot] gemini-code-assist[bot] left review comments

Reviewers whose approvals may not affect merge requirements

At least 1 approving review is required to merge this pull request.

Assignees

No one assigned

Labels

Feature Indicates a new feature addition

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

AltStyle によって変換されたページ (->オリジナル) /