Some checks failed
CI/CD Pipeline / Solidity Contracts (push) Failing after 1m20s
CI/CD Pipeline / Security Scanning (push) Successful in 2m48s
CI/CD Pipeline / Lint and Format (push) Failing after 47s
CI/CD Pipeline / Terraform Validation (push) Failing after 28s
CI/CD Pipeline / Kubernetes Validation (push) Successful in 30s
HYBX OMNL TypeScript & anchor / token-aggregation build + reconcile artifact (push) Failing after 44s
Validation / validate-genesis (push) Successful in 37s
Validation / validate-terraform (push) Failing after 42s
Validation / validate-kubernetes (push) Failing after 12s
Validation / validate-smart-contracts (push) Failing after 16m44s
Validation / validate-security (push) Failing after 20s
Validation / validate-documentation (push) Failing after 19s
Verify Deployment / Verify Deployment (push) Failing after 1m21s
Use dedicated cusdc_v2/cusdt_v2 SVG paths so GRU token alignment validation passes.
47 lines
1.4 KiB
Solidity
47 lines
1.4 KiB
Solidity
// SPDX-License-Identifier: MIT
|
|
pragma solidity ^0.8.19;
|
|
|
|
import "../libraries/RailTypes.sol";
|
|
|
|
interface IRailTriggerRegistry {
|
|
struct Trigger {
|
|
uint256 id;
|
|
RailTypes.Rail rail;
|
|
bytes32 msgType; // e.g., "pacs.008", "pain.001"
|
|
bytes32 accountRefId; // hashed account reference
|
|
bytes32 walletRefId; // hashed wallet reference (optional)
|
|
address token; // eMoney token
|
|
uint256 amount;
|
|
bytes32 currencyCode; // e.g., "USD", "EUR"
|
|
bytes32 instructionId; // end-to-end trace id
|
|
RailTypes.State state;
|
|
uint64 createdAt;
|
|
uint64 updatedAt;
|
|
}
|
|
|
|
function createTrigger(Trigger calldata t) external returns (uint256 id);
|
|
|
|
function updateState(uint256 id, RailTypes.State newState, bytes32 reason) external;
|
|
|
|
function getTrigger(uint256 id) external view returns (Trigger memory);
|
|
|
|
function getTriggerByInstructionId(bytes32 instructionId) external view returns (Trigger memory);
|
|
|
|
function triggerExists(uint256 id) external view returns (bool);
|
|
|
|
function instructionIdExists(bytes32 instructionId) external view returns (bool);
|
|
|
|
event TriggerCreated(
|
|
uint256 indexed id,
|
|
uint8 rail,
|
|
bytes32 msgType,
|
|
bytes32 instructionId,
|
|
bytes32 accountRefId,
|
|
address token,
|
|
uint256 amount
|
|
);
|
|
|
|
event TriggerStateUpdated(uint256 indexed id, uint8 oldState, uint8 newState, bytes32 reason);
|
|
}
|
|
|