-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathFlyoverDiscovery.sol
More file actions
30 lines (25 loc) · 1.28 KB
/
FlyoverDiscovery.sol
File metadata and controls
30 lines (25 loc) · 1.28 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
// SPDX-License-Identifier: MIT
pragma solidity 0.8.25;
import {Flyover} from "../libraries/Flyover.sol";
interface IFlyoverDiscovery {
event Register(uint indexed id, address indexed from, uint256 indexed amount);
event ProviderUpdate(address indexed from, string name, string apiBaseUrl);
event ProviderStatusSet(uint indexed id, bool indexed status);
error NotAuthorized(address from);
error NotEOA(address from);
error InvalidProviderData(string name, string apiBaseUrl);
error InvalidProviderType(Flyover.ProviderType providerType);
error AlreadyRegistered(address from);
error InsufficientCollateral(uint amount);
function register(
string memory name,
string memory apiBaseUrl,
bool status,
Flyover.ProviderType providerType
) external payable returns (uint);
function updateProvider(string memory name,string memory apiBaseUrl) external;
function setProviderStatus(uint providerId, bool status) external;
function getProviders() external view returns (Flyover.LiquidityProvider[] memory);
function getProvider(address providerAddress) external view returns (Flyover.LiquidityProvider memory);
function isOperational(Flyover.ProviderType providerType, address addr) external view returns (bool);
}