@@ -15,7 +15,6 @@ import {
15
15
DisableCloneCellRequest ,
16
16
DnaDefinition ,
17
17
DnaHash ,
18
- DnaSource ,
19
18
DumpFullStateRequest ,
20
19
DumpNetworkStatsRequest ,
21
20
DumpStateRequest ,
@@ -29,7 +28,6 @@ import {
29
28
GetDnaDefinitionRequest ,
30
29
getSigningCredentials ,
31
30
GrantedFunctions ,
32
- GrantedFunctionsType ,
33
31
GrantZomeCallCapabilityRequest ,
34
32
InstallAppRequest ,
35
33
IssueAppAuthenticationTokenRequest ,
@@ -412,7 +410,7 @@ export class TryCpConductor implements IConductor {
412
410
* @returns The registered DNA's {@link HoloHash}.
413
411
*/
414
412
const registerDna = async (
415
- request : RegisterDnaRequest & DnaSource
413
+ request : RegisterDnaRequest
416
414
) : Promise < DnaHash > => {
417
415
const response = await this . callAdminApi ( {
418
416
type : "register_dna" ,
@@ -800,7 +798,8 @@ export class TryCpConductor implements IConductor {
800
798
tag : "zome-call-signing-key" ,
801
799
functions,
802
800
access : {
803
- Assigned : {
801
+ type : "assigned" ,
802
+ value : {
804
803
secret : capSecret ,
805
804
assignees : [ signingKey ] ,
806
805
} ,
@@ -823,7 +822,7 @@ export class TryCpConductor implements IConductor {
823
822
const [ keyPair , signingKey ] = await generateSigningKeyPair ( ) ;
824
823
const capSecret = await grantSigningKey (
825
824
cellId ,
826
- functions || GrantedFunctionsType . All ,
825
+ functions || { type : "all" } ,
827
826
signingKey
828
827
) ;
829
828
setSigningCredentials ( cellId , { capSecret, keyPair, signingKey } ) ;
@@ -1039,22 +1038,13 @@ export class TryCpConductor implements IConductor {
1039
1038
const roles_settings = options ?. rolesSettings ;
1040
1039
const installed_app_id = options ?. installedAppId ?? `app-${ uuidv4 ( ) } ` ;
1041
1040
const network_seed = options ?. networkSeed ;
1042
- const installAppRequest : InstallAppRequest =
1043
- "bundle" in appBundleSource
1044
- ? {
1045
- bundle : appBundleSource . bundle ,
1046
- agent_key,
1047
- roles_settings,
1048
- installed_app_id,
1049
- network_seed,
1050
- }
1051
- : {
1052
- path : appBundleSource . path ,
1053
- agent_key,
1054
- roles_settings,
1055
- installed_app_id,
1056
- network_seed,
1057
- } ;
1041
+ const installAppRequest : InstallAppRequest = {
1042
+ source : appBundleSource ,
1043
+ agent_key,
1044
+ roles_settings,
1045
+ installed_app_id,
1046
+ network_seed,
1047
+ } ;
1058
1048
return this . adminWs ( ) . installApp ( installAppRequest ) ;
1059
1049
}
1060
1050
@@ -1073,22 +1063,13 @@ export class TryCpConductor implements IConductor {
1073
1063
const roles_settings = appForAgent . rolesSettings ;
1074
1064
const installed_app_id = options . installedAppId ?? `app-${ uuidv4 ( ) } ` ;
1075
1065
const network_seed = options . networkSeed ;
1076
- const installAppRequest : InstallAppRequest =
1077
- "bundle" in appForAgent . app
1078
- ? {
1079
- bundle : appForAgent . app . bundle ,
1080
- agent_key,
1081
- roles_settings,
1082
- installed_app_id,
1083
- network_seed,
1084
- }
1085
- : {
1086
- path : appForAgent . app . path ,
1087
- agent_key,
1088
- roles_settings,
1089
- installed_app_id,
1090
- network_seed,
1091
- } ;
1066
+ const installAppRequest : InstallAppRequest = {
1067
+ source : appForAgent . app ,
1068
+ agent_key,
1069
+ roles_settings,
1070
+ installed_app_id,
1071
+ network_seed,
1072
+ } ;
1092
1073
1093
1074
logger . debug (
1094
1075
`installing app with id ${ installed_app_id } for agent ${ encodeHashToBase64 (
0 commit comments