Documentation
¶
Overview ¶
Package client provides a Go SDK for the remote-signer service.
The client uses a resource-based API design (Stripe/Octokit style):
client.EVM.Sign.Execute(ctx, req) client.EVM.Rules.List(ctx, filter) client.Audit.List(ctx, filter) client.Templates.Get(ctx, id)
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNotFound = evm.ErrNotFound ErrSignerNotFound = evm.ErrSignerNotFound ErrInvalidPayload = evm.ErrInvalidPayload ErrRateLimited = evm.ErrRateLimited ErrPendingApproval = evm.ErrPendingApproval ErrRejected = evm.ErrRejected ErrBlocked = evm.ErrBlocked ErrTimeout = evm.ErrTimeout )
Re-export sentinel errors from the evm package.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// EVM provides EVM-specific operations (signing, rules, signers, HD wallets, etc.).
EVM *evm.Service
// Audit provides audit log operations.
Audit *audit.Service
// Templates provides rule template operations.
Templates *templates.Service
// contains filtered or unexported fields
}
Client is a client for the remote-signer service.
type Config ¶
type Config struct {
// BaseURL is the base URL of the remote-signer service.
BaseURL string
// APIKeyID is the API key identifier.
APIKeyID string
// PrivateKey is the Ed25519 private key for signing requests.
PrivateKey ed25519.PrivateKey
// PrivateKeyHex is an alternative way to provide the private key as hex string.
PrivateKeyHex string
// PrivateKeyBase64 is an alternative way to provide the private key in base64 DER format.
PrivateKeyBase64 string
// HTTPClient is an optional custom HTTP client.
HTTPClient *http.Client
// PollInterval is the interval between status checks when waiting for approval.
// Default: 2 seconds.
PollInterval time.Duration
// PollTimeout is the maximum time to wait for approval.
// Default: 5 minutes.
PollTimeout time.Duration
// TLSCertFile is the path to the client TLS certificate (for mTLS).
TLSCertFile string
// TLSKeyFile is the path to the client TLS private key (for mTLS).
TLSKeyFile string
// TLSCAFile is the path to the CA certificate to verify the server.
TLSCAFile string
// TLSSkipVerify skips server certificate verification.
TLSSkipVerify bool
}
Config holds configuration for creating a new Client.
type ErrorResponse ¶
type ErrorResponse = transport.ErrorResponse
ErrorResponse represents an error response from the API.
type HealthResponse ¶
HealthResponse represents the health check response.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package audit provides audit log client services for the remote-signer.
|
Package audit provides audit log client services for the remote-signer. |
|
Package evm provides EVM-specific client services for the remote-signer.
|
Package evm provides EVM-specific client services for the remote-signer. |
|
internal
|
|
|
Package mock provides per-resource mock implementations for testing.
|
Package mock provides per-resource mock implementations for testing. |
|
Package templates provides template client services for the remote-signer.
|
Package templates provides template client services for the remote-signer. |
Click to show internal directories.
Click to hide internal directories.