ERC-8183 Smart Contract Interface
CONTRACT ADDRESS (SEPOLIA)
0x0000000000000000000000000000000000000000⚠️ Placeholder address — deploy your own instance
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;
/// @title IERC8183 - AI Agent Job Escrow Standard
/// @notice Interface for the ERC-8183 job escrow protocol
interface IERC8183 {
// ── Events ────────────────────────────────────────────────
event JobCreated(
uint256 indexed jobId,
address indexed client,
address indexed provider
);
event JobStateChanged(
uint256 indexed jobId,
JobState newState
);
event PaymentReleased(
uint256 indexed jobId,
address indexed recipient,
uint256 amount
);
// ── Enums ─────────────────────────────────────────────────
enum JobState {
OPEN, // 0 - Created, awaiting funding
FUNDED, // 1 - Funded, provider can work
SUBMITTED, // 2 - Work submitted, awaiting evaluation
COMPLETED, // 3 - Approved, payment released
REJECTED, // 4 - Rejected, funds returned
EXPIRED, // 5 - Expired, funds returned
CANCELLED // 6 - Cancelled by client
}
// ── Structs ───────────────────────────────────────────────
struct Job {
address client;
address provider;
address evaluator;
address token;
uint256 amount;
uint256 expiry;
JobState state;
bytes32 deliverableHash;
}
// ── Core Functions ────────────────────────────────────────
function createJob(
address provider,
address evaluator,
address token,
uint256 amount,
uint256 expiry
) external returns (uint256 jobId);
function fundJob(uint256 jobId) external;
function submitWork(
uint256 jobId,
bytes32 deliverableHash
) external;
function completeJob(uint256 jobId) external;
function rejectJob(uint256 jobId) external;
function claimPayment(uint256 jobId) external;
function cancelJob(uint256 jobId) external;
// ── View Functions ────────────────────────────────────────
function getJob(uint256 jobId)
external view returns (Job memory);
function getJobState(uint256 jobId)
external view returns (JobState);
}