Type alias DataRegistryIdlTypes

DataRegistryIdlTypes: {
    accounts: [{
        discriminator: [85, 240, 182, 158, 76, 7, 18, 233];
        name: "dataAccount";
    }, {
        discriminator: [57, 174, 76, 239, 133, 18, 173, 209];
        name: "dataRegistryAccount";
    }];
    address: "dataeP5X1e7XsWN1ovDSEDP5cqaEUnKBmHE5iZhXPVw";
    errors: [{
        code: 6000;
        msg: "The signer is not authorized to perform this action";
        name: "unauthorizedSigner";
    }];
    instructions: [{
        accounts: [{
            name: "payer";
            signer: true;
            writable: true;
        }, {
            name: "signer";
            signer: true;
        }, {
            name: "dataRegistry";
        }, {
            name: "dataAccount";
            signer: true;
            writable: true;
        }, {
            address: "11111111111111111111111111111111";
            name: "systemProgram";
        }];
        args: [{
            name: "args";
            type: {
                defined: {
                    name: "createDataAccountArgs";
                };
            };
        }];
        discriminator: [129, 132, 92, 50, 136, 89, 37, 100];
        docs: ["data functions", "create data account"];
        name: "createDataAccount";
    }, {
        accounts: [{
            name: "payer";
            signer: true;
            writable: true;
        }, {
            name: "signer";
            signer: true;
        }, {
            name: "assetMint";
        }, {
            name: "dataRegistry";
            pda: {
                seeds: [{
                    kind: "account";
                    path: "assetMint";
                }];
            };
            writable: true;
        }, {
            address: "11111111111111111111111111111111";
            name: "systemProgram";
        }];
        args: [{
            name: "authority";
            type: "pubkey";
        }, {
            name: "delegate";
            type: {
                option: "pubkey";
            };
        }];
        discriminator: [206, 245, 133, 230, 73, 246, 116, 101];
        docs: ["registry functions", "create data registry"];
        name: "createDataRegistry";
    }, {
        accounts: [{
            name: "authority";
            signer: true;
        }, {
            name: "dataRegistry";
            writable: true;
        }];
        args: [{
            name: "delegate";
            type: "pubkey";
        }];
        discriminator: [173, 92, 229, 22, 152, 104, 168, 224];
        docs: ["delegate data registry"];
        name: "delegateDataRegsitry";
    }, {
        accounts: [{
            name: "signer";
            signer: true;
        }, {
            name: "dataRegistry";
        }, {
            name: "dataAccount";
            writable: true;
        }];
        args: [];
        discriminator: [159, 5, 34, 220, 166, 192, 76, 92];
        docs: ["delete data account"];
        name: "deleteDataAccount";
    }, {
        accounts: [{
            name: "signer";
            signer: true;
        }, {
            name: "dataRegistry";
        }, {
            name: "dataAccount";
            writable: true;
        }];
        args: [{
            name: "args";
            type: {
                defined: {
                    name: "updateDataAccountArgs";
                };
            };
        }];
        discriminator: [90, 215, 94, 10, 209, 249, 11, 148];
        docs: ["update data account"];
        name: "updateDataAccount";
    }];
    metadata: {
        description: "The Data Registry Program (DRP) enables the ledger of generic asset data.";
        name: "dataRegistry";
        repository: "https://github.com/bridgesplit/rwa";
        spec: "0.1.0";
        version: "0.0.1";
    };
    types: [{
        name: "createDataAccountArgs";
        type: {
            fields: [{
                name: "type";
                type: {
                    defined: {
                        name: "dataAccountType";
                    };
                };
            }, {
                name: "name";
                type: "string";
            }, {
                name: "uri";
                type: "string";
            }];
            kind: "struct";
        };
    }, {
        name: "dataAccount";
        type: {
            fields: [{
                name: "version";
                type: "u8";
            }, {
                docs: ["data registry to which the account belongs"];
                name: "dataRegistry";
                type: "pubkey";
            }, {
                docs: ["type of the data account"];
                name: "type";
                type: {
                    defined: {
                        name: "dataAccountType";
                    };
                };
            }, {
                docs: ["used by creator to store name of the document"];
                name: "name";
                type: "string";
            }, {
                docs: ["uri pointing to the data stored in the document"];
                name: "uri";
                type: "string";
            }];
            kind: "struct";
        };
    }, {
        name: "dataAccountType";
        type: {
            kind: "enum";
            variants: [{
                name: "title";
            }, {
                name: "legal";
            }, {
                name: "tax";
            }, {
                name: "miscellaneous";
            }];
        };
    }, {
        name: "dataRegistryAccount";
        type: {
            fields: [{
                name: "version";
                type: "u8";
            }, {
                name: "assetMint";
                type: "pubkey";
            }, {
                docs: ["can sign creation of new data accounts", "can update delegate", "can update data account authority"];
                name: "authority";
                type: "pubkey";
            }, {
                docs: ["can sign creation of new data accounts, can be used if a different org needs to issue data accounts"];
                name: "delegate";
                type: "pubkey";
            }];
            kind: "struct";
        };
    }, {
        name: "updateDataAccountArgs";
        type: {
            fields: [{
                name: "type";
                type: {
                    defined: {
                        name: "dataAccountType";
                    };
                };
            }, {
                name: "name";
                type: "string";
            }, {
                name: "uri";
                type: "string";
            }];
            kind: "struct";
        };
    }];
}

Program IDL in camelCase format in order to be used in JS/TS.

Note that this is only a type helper and is not the actual IDL. The original IDL can be found at target/idl/data_registry.json.

Type declaration

  • accounts: [{
        discriminator: [85, 240, 182, 158, 76, 7, 18, 233];
        name: "dataAccount";
    }, {
        discriminator: [57, 174, 76, 239, 133, 18, 173, 209];
        name: "dataRegistryAccount";
    }]
  • address: "dataeP5X1e7XsWN1ovDSEDP5cqaEUnKBmHE5iZhXPVw"
  • errors: [{
        code: 6000;
        msg: "The signer is not authorized to perform this action";
        name: "unauthorizedSigner";
    }]
  • instructions: [{
        accounts: [{
            name: "payer";
            signer: true;
            writable: true;
        }, {
            name: "signer";
            signer: true;
        }, {
            name: "dataRegistry";
        }, {
            name: "dataAccount";
            signer: true;
            writable: true;
        }, {
            address: "11111111111111111111111111111111";
            name: "systemProgram";
        }];
        args: [{
            name: "args";
            type: {
                defined: {
                    name: "createDataAccountArgs";
                };
            };
        }];
        discriminator: [129, 132, 92, 50, 136, 89, 37, 100];
        docs: ["data functions", "create data account"];
        name: "createDataAccount";
    }, {
        accounts: [{
            name: "payer";
            signer: true;
            writable: true;
        }, {
            name: "signer";
            signer: true;
        }, {
            name: "assetMint";
        }, {
            name: "dataRegistry";
            pda: {
                seeds: [{
                    kind: "account";
                    path: "assetMint";
                }];
            };
            writable: true;
        }, {
            address: "11111111111111111111111111111111";
            name: "systemProgram";
        }];
        args: [{
            name: "authority";
            type: "pubkey";
        }, {
            name: "delegate";
            type: {
                option: "pubkey";
            };
        }];
        discriminator: [206, 245, 133, 230, 73, 246, 116, 101];
        docs: ["registry functions", "create data registry"];
        name: "createDataRegistry";
    }, {
        accounts: [{
            name: "authority";
            signer: true;
        }, {
            name: "dataRegistry";
            writable: true;
        }];
        args: [{
            name: "delegate";
            type: "pubkey";
        }];
        discriminator: [173, 92, 229, 22, 152, 104, 168, 224];
        docs: ["delegate data registry"];
        name: "delegateDataRegsitry";
    }, {
        accounts: [{
            name: "signer";
            signer: true;
        }, {
            name: "dataRegistry";
        }, {
            name: "dataAccount";
            writable: true;
        }];
        args: [];
        discriminator: [159, 5, 34, 220, 166, 192, 76, 92];
        docs: ["delete data account"];
        name: "deleteDataAccount";
    }, {
        accounts: [{
            name: "signer";
            signer: true;
        }, {
            name: "dataRegistry";
        }, {
            name: "dataAccount";
            writable: true;
        }];
        args: [{
            name: "args";
            type: {
                defined: {
                    name: "updateDataAccountArgs";
                };
            };
        }];
        discriminator: [90, 215, 94, 10, 209, 249, 11, 148];
        docs: ["update data account"];
        name: "updateDataAccount";
    }]
  • metadata: {
        description: "The Data Registry Program (DRP) enables the ledger of generic asset data.";
        name: "dataRegistry";
        repository: "https://github.com/bridgesplit/rwa";
        spec: "0.1.0";
        version: "0.0.1";
    }
    • description: "The Data Registry Program (DRP) enables the ledger of generic asset data."
    • name: "dataRegistry"
    • repository: "https://github.com/bridgesplit/rwa"
    • spec: "0.1.0"
    • version: "0.0.1"
  • types: [{
        name: "createDataAccountArgs";
        type: {
            fields: [{
                name: "type";
                type: {
                    defined: {
                        name: "dataAccountType";
                    };
                };
            }, {
                name: "name";
                type: "string";
            }, {
                name: "uri";
                type: "string";
            }];
            kind: "struct";
        };
    }, {
        name: "dataAccount";
        type: {
            fields: [{
                name: "version";
                type: "u8";
            }, {
                docs: ["data registry to which the account belongs"];
                name: "dataRegistry";
                type: "pubkey";
            }, {
                docs: ["type of the data account"];
                name: "type";
                type: {
                    defined: {
                        name: "dataAccountType";
                    };
                };
            }, {
                docs: ["used by creator to store name of the document"];
                name: "name";
                type: "string";
            }, {
                docs: ["uri pointing to the data stored in the document"];
                name: "uri";
                type: "string";
            }];
            kind: "struct";
        };
    }, {
        name: "dataAccountType";
        type: {
            kind: "enum";
            variants: [{
                name: "title";
            }, {
                name: "legal";
            }, {
                name: "tax";
            }, {
                name: "miscellaneous";
            }];
        };
    }, {
        name: "dataRegistryAccount";
        type: {
            fields: [{
                name: "version";
                type: "u8";
            }, {
                name: "assetMint";
                type: "pubkey";
            }, {
                docs: ["can sign creation of new data accounts", "can update delegate", "can update data account authority"];
                name: "authority";
                type: "pubkey";
            }, {
                docs: ["can sign creation of new data accounts, can be used if a different org needs to issue data accounts"];
                name: "delegate";
                type: "pubkey";
            }];
            kind: "struct";
        };
    }, {
        name: "updateDataAccountArgs";
        type: {
            fields: [{
                name: "type";
                type: {
                    defined: {
                        name: "dataAccountType";
                    };
                };
            }, {
                name: "name";
                type: "string";
            }, {
                name: "uri";
                type: "string";
            }];
            kind: "struct";
        };
    }]