Build an integration
Define the operations the adapter exposes before adding convenience functions. Each operation should state its database selection, input values, result shape and failure behavior. Keep the application's connection configuration separate from SQL text.
Start with a read
An HTTP-based adapter can begin with the following request against the supplied local configuration:
curl --fail --silent --user default: \
--data-binary 'SELECT 1 AS connected FORMAT json_each_row' \
'http://127.0.0.1:7401/?database=data'{"connected":1}Preserve the response status and diagnostic headers before decoding the selected format. A health check and an authenticated SQL query serve different purposes. Follow the HTTP reference for accepted parameters, authentication and response limits.
Add writes deliberately
Document how the adapter sends input rows and handles an uncertain write outcome. Keep a transaction's statements in one HTTP request, or on the same native connection, as required by the session contract.
Use a documented binding API where available; HTTP does not provide bound parameters. Handle large numeric values and nulls explicitly when decoding results. Add integration tests before claiming that a format or operation is supported.