@dcl/sdk 7.0.0-2982061039.commit-9cc9ea8 → 7.0.0-3000191624.commit-0ff97dc
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ecs7/index.js +4 -4
- package/dist/ecs7/index.min.js +1 -1
- package/dist/ecs7/index.min.js.map +1 -1
- package/package.json +4 -4
- package/types/rpc-modules/CommunicationsController/index.d.ts +14 -0
- package/types/rpc-modules/DevTools/index.d.ts +15 -0
- package/types/rpc-modules/EngineAPI/index.d.ts +160 -0
- package/types/rpc-modules/EnvironmentAPI/index.d.ts +81 -0
- package/types/rpc-modules/EthereumController/index.d.ts +60 -0
- package/types/rpc-modules/ExperimentalAPI/index.d.ts +20 -0
- package/types/rpc-modules/ParcelIdentity/index.d.ts +48 -0
- package/types/rpc-modules/Permissions/index.d.ts +30 -0
- package/types/rpc-modules/Players/index.d.ts +52 -0
- package/types/rpc-modules/PortableExperiences/index.d.ts +38 -0
- package/types/rpc-modules/RestrictedActions/index.d.ts +26 -0
- package/types/rpc-modules/SceneStateStorageController/index.d.ts +90 -0
- package/types/rpc-modules/SignedFetch/index.d.ts +37 -0
- package/types/rpc-modules/SocialController/index.d.ts +18 -0
- package/types/rpc-modules/UserActionModule/index.d.ts +14 -0
- package/types/rpc-modules/UserIdentity/index.d.ts +45 -0
- package/types/tsconfig.ecs7.json +15 -11
- package/types/@decentraland/CommunicationsController/index.d.ts +0 -7
- package/types/@decentraland/EnvironmentAPI/index.d.ts +0 -45
- package/types/@decentraland/EthereumController/index.d.ts +0 -47
- package/types/@decentraland/Identity/index.d.ts +0 -44
- package/types/@decentraland/ParcelIdentity/index.d.ts +0 -49
- package/types/@decentraland/Players/index.d.ts +0 -49
- package/types/@decentraland/PortableExperiences/index.d.ts +0 -39
- package/types/@decentraland/RestrictedActions/index.d.ts +0 -41
- package/types/@decentraland/SignedFetch/index.d.ts +0 -16
- package/types/@decentraland/SocialController/index.d.ts +0 -1
- package/types/@decentraland/web3-provider/index.d.ts +0 -7
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@dcl/sdk",
|
3
|
-
"version": "7.0.0-
|
3
|
+
"version": "7.0.0-3000191624.commit-0ff97dc",
|
4
4
|
"description": "",
|
5
5
|
"main": "dist/src/index.js",
|
6
6
|
"typings": "dist/index.d.ts",
|
@@ -27,8 +27,8 @@
|
|
27
27
|
"src/cli/**/*.js"
|
28
28
|
],
|
29
29
|
"dependencies": {
|
30
|
-
"@dcl/amd": "6.11.7-
|
31
|
-
"@dcl/build-ecs": "6.11.7-
|
30
|
+
"@dcl/amd": "6.11.7-3000191624.commit-0ff97dc",
|
31
|
+
"@dcl/build-ecs": "6.11.7-3000191624.commit-0ff97dc",
|
32
32
|
"@dcl/kernel": "1.0.0-2638443584.commit-696a74b",
|
33
33
|
"@dcl/posix": "^1.0.4",
|
34
34
|
"@dcl/schemas": "4.8.0",
|
@@ -38,5 +38,5 @@
|
|
38
38
|
"ignore": "^5.1.8"
|
39
39
|
},
|
40
40
|
"minCliVersion": "3.10.2",
|
41
|
-
"commit": "
|
41
|
+
"commit": "0ff97dc9c8394aec098148b4b99bd02a898ac0f9"
|
42
42
|
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
declare module "~system/CommunicationsController" {
|
2
|
+
|
3
|
+
export interface RealSendRequest {
|
4
|
+
message: string;
|
5
|
+
}
|
6
|
+
export interface RealSendResponse {
|
7
|
+
}
|
8
|
+
|
9
|
+
// ########### BLOCK
|
10
|
+
|
11
|
+
// importtype { RealSendRequest, RealSendResponse } from "proto/CommunicationsController.gen";
|
12
|
+
export function send(body: RealSendRequest): Promise<RealSendResponse>;
|
13
|
+
|
14
|
+
}
|
@@ -0,0 +1,15 @@
|
|
1
|
+
declare module "~system/DevTools" {
|
2
|
+
|
3
|
+
export interface DevToolsBody {
|
4
|
+
type: string;
|
5
|
+
jsonPayload: string;
|
6
|
+
}
|
7
|
+
export interface EventResponse {
|
8
|
+
}
|
9
|
+
|
10
|
+
// ########### BLOCK
|
11
|
+
|
12
|
+
// importtype { DevToolsBody, EventResponse } from "proto/DevTools.gen";
|
13
|
+
export function event(body: DevToolsBody): Promise<EventResponse>;
|
14
|
+
|
15
|
+
}
|
@@ -0,0 +1,160 @@
|
|
1
|
+
declare module "~system/EngineAPI" {
|
2
|
+
|
3
|
+
export enum QueryType {
|
4
|
+
InvalidQueryType = 0,
|
5
|
+
HitFirst = 1,
|
6
|
+
HitAll = 2,
|
7
|
+
HitFirstAvatar = 3,
|
8
|
+
HitAllAvatars = 4,
|
9
|
+
UNRECOGNIZED = -1
|
10
|
+
}
|
11
|
+
export enum EAType {
|
12
|
+
InvalidEAType = 0,
|
13
|
+
OpenExternalUrl = 1,
|
14
|
+
OpenNFTDialog = 2,
|
15
|
+
CreateEntity = 3,
|
16
|
+
RemoveEntity = 4,
|
17
|
+
UpdateEntityComponent = 5,
|
18
|
+
AttachEntityComponent = 6,
|
19
|
+
ComponentRemoved = 7,
|
20
|
+
SetEntityParent = 8,
|
21
|
+
Query = 9,
|
22
|
+
ComponentCreated = 10,
|
23
|
+
ComponentDisposed = 11,
|
24
|
+
ComponentUpdated = 12,
|
25
|
+
InitMessagesFinished = 13,
|
26
|
+
UNRECOGNIZED = -1
|
27
|
+
}
|
28
|
+
/** Events */
|
29
|
+
export enum EventDataType {
|
30
|
+
Generic = 0,
|
31
|
+
PositionChanged = 1,
|
32
|
+
RotationChanged = 2,
|
33
|
+
UNRECOGNIZED = -1
|
34
|
+
}
|
35
|
+
export interface OpenExternalUrlBody {
|
36
|
+
url: string;
|
37
|
+
}
|
38
|
+
export interface OpenNFTDialogBody {
|
39
|
+
assetContractAddress: string;
|
40
|
+
tokenId: string;
|
41
|
+
comment?: string | undefined;
|
42
|
+
}
|
43
|
+
export interface CreateEntityBody {
|
44
|
+
id: string;
|
45
|
+
}
|
46
|
+
export interface RemoveEntityBody {
|
47
|
+
id: string;
|
48
|
+
}
|
49
|
+
export interface UpdateEntityComponentBody {
|
50
|
+
entityId: string;
|
51
|
+
classId: number;
|
52
|
+
name: string;
|
53
|
+
json: string;
|
54
|
+
}
|
55
|
+
export interface AttachEntityComponentBody {
|
56
|
+
entityId: string;
|
57
|
+
name: string;
|
58
|
+
id: string;
|
59
|
+
}
|
60
|
+
export interface ComponentRemovedBody {
|
61
|
+
entityId: string;
|
62
|
+
name: string;
|
63
|
+
}
|
64
|
+
export interface SetEntityParentBody {
|
65
|
+
entityId: string;
|
66
|
+
parentId: string;
|
67
|
+
}
|
68
|
+
export interface QueryBody {
|
69
|
+
queryId: QueryType;
|
70
|
+
payload: string;
|
71
|
+
}
|
72
|
+
export interface ComponentCreatedBody {
|
73
|
+
id: string;
|
74
|
+
classId: number;
|
75
|
+
name: string;
|
76
|
+
}
|
77
|
+
export interface ComponentDisposedBody {
|
78
|
+
id: string;
|
79
|
+
}
|
80
|
+
export interface ComponentUpdatedBody {
|
81
|
+
id: string;
|
82
|
+
json: string;
|
83
|
+
}
|
84
|
+
export interface InitMessagesFinishedBody {
|
85
|
+
}
|
86
|
+
export interface Payload {
|
87
|
+
openExternalUrl?: OpenExternalUrlBody | undefined;
|
88
|
+
openNftDialog?: OpenNFTDialogBody | undefined;
|
89
|
+
createEntity?: CreateEntityBody | undefined;
|
90
|
+
removeEntity?: RemoveEntityBody | undefined;
|
91
|
+
updateEntityComponent?: UpdateEntityComponentBody | undefined;
|
92
|
+
attachEntityComponent?: AttachEntityComponentBody | undefined;
|
93
|
+
componentRemoved?: ComponentRemovedBody | undefined;
|
94
|
+
setEntityParent?: SetEntityParentBody | undefined;
|
95
|
+
query?: QueryBody | undefined;
|
96
|
+
componentCreated?: ComponentCreatedBody | undefined;
|
97
|
+
componentDisposed?: ComponentDisposedBody | undefined;
|
98
|
+
componentUpdated?: ComponentUpdatedBody | undefined;
|
99
|
+
initMessagesFinished?: InitMessagesFinishedBody | undefined;
|
100
|
+
}
|
101
|
+
export interface EntityAction {
|
102
|
+
type: EAType;
|
103
|
+
tag?: string | undefined;
|
104
|
+
payload: Payload | undefined;
|
105
|
+
}
|
106
|
+
export interface ManyEntityAction {
|
107
|
+
actions: EntityAction[];
|
108
|
+
}
|
109
|
+
export interface SendBatchResponse {
|
110
|
+
events: EventData[];
|
111
|
+
}
|
112
|
+
export interface UnsubscribeRequest {
|
113
|
+
eventId: string;
|
114
|
+
}
|
115
|
+
export interface SubscribeRequest {
|
116
|
+
eventId: string;
|
117
|
+
}
|
118
|
+
export interface SubscribeResponse {
|
119
|
+
}
|
120
|
+
export interface UnsubscribeResponse {
|
121
|
+
}
|
122
|
+
export interface GenericPayload {
|
123
|
+
eventId: string;
|
124
|
+
eventData: string;
|
125
|
+
}
|
126
|
+
export interface ReadOnlyVector3 {
|
127
|
+
x: number;
|
128
|
+
y: number;
|
129
|
+
z: number;
|
130
|
+
}
|
131
|
+
export interface ReadOnlyQuaternion {
|
132
|
+
x: number;
|
133
|
+
y: number;
|
134
|
+
z: number;
|
135
|
+
w: number;
|
136
|
+
}
|
137
|
+
export interface PositionChangedPayload {
|
138
|
+
position: ReadOnlyVector3 | undefined;
|
139
|
+
cameraPosition: ReadOnlyVector3 | undefined;
|
140
|
+
playerHeight: number;
|
141
|
+
}
|
142
|
+
export interface RotationChangedPayload {
|
143
|
+
rotation: ReadOnlyVector3 | undefined;
|
144
|
+
quaternion: ReadOnlyQuaternion | undefined;
|
145
|
+
}
|
146
|
+
export interface EventData {
|
147
|
+
type: EventDataType;
|
148
|
+
generic?: GenericPayload | undefined;
|
149
|
+
positionChanged?: PositionChangedPayload | undefined;
|
150
|
+
rotationChanged?: RotationChangedPayload | undefined;
|
151
|
+
}
|
152
|
+
|
153
|
+
// ########### BLOCK
|
154
|
+
|
155
|
+
// importtype { ManyEntityAction, SendBatchResponse, SubscribeRequest, SubscribeResponse, UnsubscribeRequest, UnsubscribeResponse } from "proto/EngineAPI.gen";
|
156
|
+
export function sendBatch(body: ManyEntityAction): Promise<SendBatchResponse>;
|
157
|
+
export function subscribe(body: SubscribeRequest): Promise<SubscribeResponse>;
|
158
|
+
export function unsubscribe(body: UnsubscribeRequest): Promise<UnsubscribeResponse>;
|
159
|
+
|
160
|
+
}
|
@@ -0,0 +1,81 @@
|
|
1
|
+
declare module "~system/EnvironmentAPI" {
|
2
|
+
|
3
|
+
|
4
|
+
export interface ContentMapping {
|
5
|
+
file: string;
|
6
|
+
hash: string;
|
7
|
+
}
|
8
|
+
|
9
|
+
// ########### BLOCK
|
10
|
+
|
11
|
+
// importtype { ContentMapping } from "proto/common/ContentMapping.gen";
|
12
|
+
export interface MinimalRunnableEntity {
|
13
|
+
content: ContentMapping[];
|
14
|
+
metadataJson: string;
|
15
|
+
}
|
16
|
+
export interface BootstrapDataResponse {
|
17
|
+
id: string;
|
18
|
+
baseUrl: string;
|
19
|
+
entity: MinimalRunnableEntity | undefined;
|
20
|
+
useFPSThrottling: boolean;
|
21
|
+
}
|
22
|
+
export interface PreviewModeResponse {
|
23
|
+
isPreview: boolean;
|
24
|
+
}
|
25
|
+
export interface AreUnsafeRequestAllowedResponse {
|
26
|
+
status: boolean;
|
27
|
+
}
|
28
|
+
export interface GetPlatformResponse {
|
29
|
+
platform: string;
|
30
|
+
}
|
31
|
+
export interface EnvironmentRealm {
|
32
|
+
domain: string;
|
33
|
+
layer: string;
|
34
|
+
room: string;
|
35
|
+
serverName: string;
|
36
|
+
displayName: string;
|
37
|
+
protocol: string;
|
38
|
+
}
|
39
|
+
export interface GetCurrentRealmResponse {
|
40
|
+
currentRealm?: EnvironmentRealm | undefined;
|
41
|
+
}
|
42
|
+
export interface GetExplorerConfigurationResponse {
|
43
|
+
clientUri: string;
|
44
|
+
configurations: {
|
45
|
+
[key: string]: string;
|
46
|
+
};
|
47
|
+
}
|
48
|
+
export interface GetExplorerConfigurationResponse_ConfigurationsEntry {
|
49
|
+
key: string;
|
50
|
+
value: string;
|
51
|
+
}
|
52
|
+
export interface GetDecentralandTimeResponse {
|
53
|
+
seconds: number;
|
54
|
+
}
|
55
|
+
export interface GetBootstrapDataRequest {
|
56
|
+
}
|
57
|
+
export interface IsPreviewModeRequest {
|
58
|
+
}
|
59
|
+
export interface GetPlatformRequest {
|
60
|
+
}
|
61
|
+
export interface AreUnsafeRequestAllowedRequest {
|
62
|
+
}
|
63
|
+
export interface GetCurrentRealmRequest {
|
64
|
+
}
|
65
|
+
export interface GetExplorerConfigurationRequest {
|
66
|
+
}
|
67
|
+
export interface GetDecentralandTimeRequest {
|
68
|
+
}
|
69
|
+
|
70
|
+
// ########### BLOCK
|
71
|
+
|
72
|
+
// importtype { GetBootstrapDataRequest, BootstrapDataResponse, IsPreviewModeRequest, PreviewModeResponse, GetPlatformRequest, GetPlatformResponse, AreUnsafeRequestAllowedRequest, AreUnsafeRequestAllowedResponse, GetCurrentRealmRequest, GetCurrentRealmResponse, GetExplorerConfigurationRequest, GetExplorerConfigurationResponse, GetDecentralandTimeRequest, GetDecentralandTimeResponse } from "proto/EnvironmentAPI.gen";
|
73
|
+
export function getBootstrapData(body: GetBootstrapDataRequest): Promise<BootstrapDataResponse>;
|
74
|
+
export function isPreviewMode(body: IsPreviewModeRequest): Promise<PreviewModeResponse>;
|
75
|
+
export function getPlatform(body: GetPlatformRequest): Promise<GetPlatformResponse>;
|
76
|
+
export function areUnsafeRequestAllowed(body: AreUnsafeRequestAllowedRequest): Promise<AreUnsafeRequestAllowedResponse>;
|
77
|
+
export function getCurrentRealm(body: GetCurrentRealmRequest): Promise<GetCurrentRealmResponse>;
|
78
|
+
export function getExplorerConfiguration(body: GetExplorerConfigurationRequest): Promise<GetExplorerConfigurationResponse>;
|
79
|
+
export function getDecentralandTime(body: GetDecentralandTimeRequest): Promise<GetDecentralandTimeResponse>;
|
80
|
+
|
81
|
+
}
|
@@ -0,0 +1,60 @@
|
|
1
|
+
declare module "~system/EthereumController" {
|
2
|
+
|
3
|
+
export interface RequirePaymentRequest {
|
4
|
+
toAddress: string;
|
5
|
+
amount: number;
|
6
|
+
currency: string;
|
7
|
+
}
|
8
|
+
export interface RequirePaymentResponse {
|
9
|
+
jsonAnyResponse: string;
|
10
|
+
}
|
11
|
+
export interface SignMessageRequest {
|
12
|
+
message: {
|
13
|
+
[key: string]: string;
|
14
|
+
};
|
15
|
+
}
|
16
|
+
export interface SignMessageRequest_MessageEntry {
|
17
|
+
key: string;
|
18
|
+
value: string;
|
19
|
+
}
|
20
|
+
export interface SignMessageResponse {
|
21
|
+
message: string;
|
22
|
+
hexEncodedMessage: string;
|
23
|
+
signature: string;
|
24
|
+
}
|
25
|
+
export interface ConvertMessageToObjectRequest {
|
26
|
+
message: string;
|
27
|
+
}
|
28
|
+
export interface ConvertMessageToObjectResponse {
|
29
|
+
dict: {
|
30
|
+
[key: string]: string;
|
31
|
+
};
|
32
|
+
}
|
33
|
+
export interface ConvertMessageToObjectResponse_DictEntry {
|
34
|
+
key: string;
|
35
|
+
value: string;
|
36
|
+
}
|
37
|
+
export interface SendAsyncRequest {
|
38
|
+
id: number;
|
39
|
+
method: string;
|
40
|
+
jsonParams: string;
|
41
|
+
}
|
42
|
+
export interface SendAsyncResponse {
|
43
|
+
jsonAnyResponse: string;
|
44
|
+
}
|
45
|
+
export interface GetUserAccountRequest {
|
46
|
+
}
|
47
|
+
export interface GetUserAccountResponse {
|
48
|
+
address?: string | undefined;
|
49
|
+
}
|
50
|
+
|
51
|
+
// ########### BLOCK
|
52
|
+
|
53
|
+
// importtype { RequirePaymentRequest, RequirePaymentResponse, SignMessageRequest, SignMessageResponse, ConvertMessageToObjectRequest, ConvertMessageToObjectResponse, SendAsyncRequest, SendAsyncResponse, GetUserAccountRequest, GetUserAccountResponse } from "proto/EthereumController.gen";
|
54
|
+
export function requirePayment(body: RequirePaymentRequest): Promise<RequirePaymentResponse>;
|
55
|
+
export function signMessage(body: SignMessageRequest): Promise<SignMessageResponse>;
|
56
|
+
export function convertMessageToObject(body: ConvertMessageToObjectRequest): Promise<ConvertMessageToObjectResponse>;
|
57
|
+
export function sendAsync(body: SendAsyncRequest): Promise<SendAsyncResponse>;
|
58
|
+
export function getUserAccount(body: GetUserAccountRequest): Promise<GetUserAccountResponse>;
|
59
|
+
|
60
|
+
}
|
@@ -0,0 +1,20 @@
|
|
1
|
+
declare module "~system/ExperimentalAPI" {
|
2
|
+
|
3
|
+
export interface SendToRendererRequest {
|
4
|
+
data: Uint8Array;
|
5
|
+
}
|
6
|
+
export interface SendToResponse {
|
7
|
+
}
|
8
|
+
export interface MessageFromRendererRequest {
|
9
|
+
}
|
10
|
+
export interface MessageFromRendererResponse {
|
11
|
+
data: Uint8Array[];
|
12
|
+
}
|
13
|
+
|
14
|
+
// ########### BLOCK
|
15
|
+
|
16
|
+
// importtype { SendToRendererRequest, SendToResponse, MessageFromRendererRequest, MessageFromRendererResponse } from "proto/ExperimentalAPI.gen";
|
17
|
+
export function sendToRenderer(body: SendToRendererRequest): Promise<SendToResponse>;
|
18
|
+
export function messageFromRenderer(body: MessageFromRendererRequest): Promise<MessageFromRendererResponse>;
|
19
|
+
|
20
|
+
}
|
@@ -0,0 +1,48 @@
|
|
1
|
+
declare module "~system/ParcelIdentity" {
|
2
|
+
|
3
|
+
|
4
|
+
export interface ContentMapping {
|
5
|
+
file: string;
|
6
|
+
hash: string;
|
7
|
+
}
|
8
|
+
|
9
|
+
// ########### BLOCK
|
10
|
+
|
11
|
+
// importtype { ContentMapping } from "proto/common/ContentMapping.gen";
|
12
|
+
export interface MappingsResponse {
|
13
|
+
parcelId: string;
|
14
|
+
rootCid: string;
|
15
|
+
contents: ContentMapping[];
|
16
|
+
}
|
17
|
+
export interface Land {
|
18
|
+
sceneId: string;
|
19
|
+
sceneJsonData: string;
|
20
|
+
baseUrl: string;
|
21
|
+
baseUrlBundles: string;
|
22
|
+
mappingsResponse: MappingsResponse | undefined;
|
23
|
+
}
|
24
|
+
export interface GetParcelRequest {
|
25
|
+
}
|
26
|
+
export interface GetParcelResponse {
|
27
|
+
land: Land | undefined;
|
28
|
+
cid: string;
|
29
|
+
}
|
30
|
+
export interface GetSceneIdRequest {
|
31
|
+
}
|
32
|
+
export interface GetSceneIdResponse {
|
33
|
+
sceneId: string;
|
34
|
+
}
|
35
|
+
export interface GetIsEmptyRequest {
|
36
|
+
}
|
37
|
+
export interface GetIsEmptyResponse {
|
38
|
+
isEmpty: boolean;
|
39
|
+
}
|
40
|
+
|
41
|
+
// ########### BLOCK
|
42
|
+
|
43
|
+
// importtype { GetParcelRequest, GetParcelResponse, GetSceneIdRequest, GetSceneIdResponse, GetIsEmptyRequest, GetIsEmptyResponse } from "proto/ParcelIdentity.gen";
|
44
|
+
export function getParcel(body: GetParcelRequest): Promise<GetParcelResponse>;
|
45
|
+
export function getSceneId(body: GetSceneIdRequest): Promise<GetSceneIdResponse>;
|
46
|
+
export function getIsEmpty(body: GetIsEmptyRequest): Promise<GetIsEmptyResponse>;
|
47
|
+
|
48
|
+
}
|
@@ -0,0 +1,30 @@
|
|
1
|
+
declare module "~system/Permissions" {
|
2
|
+
|
3
|
+
export enum PermissionItem {
|
4
|
+
ALLOW_TO_MOVE_PLAYER_INSIDE_SCENE = 0,
|
5
|
+
ALLOW_TO_TRIGGER_AVATAR_EMOTE = 1,
|
6
|
+
USE_WEB3_API = 2,
|
7
|
+
USE_WEBSOCKET = 3,
|
8
|
+
USE_FETCH = 4,
|
9
|
+
UNRECOGNIZED = -1
|
10
|
+
}
|
11
|
+
export interface PermissionResponse {
|
12
|
+
hasPermission: boolean;
|
13
|
+
}
|
14
|
+
export interface HasPermissionRequest {
|
15
|
+
permission: PermissionItem;
|
16
|
+
}
|
17
|
+
export interface HasManyPermissionRequest {
|
18
|
+
permissions: PermissionItem[];
|
19
|
+
}
|
20
|
+
export interface HasManyPermissionResponse {
|
21
|
+
hasManyPermission: boolean[];
|
22
|
+
}
|
23
|
+
|
24
|
+
// ########### BLOCK
|
25
|
+
|
26
|
+
// importtype { HasPermissionRequest, PermissionResponse, HasManyPermissionRequest, HasManyPermissionResponse } from "proto/Permissions.gen";
|
27
|
+
export function hasPermission(body: HasPermissionRequest): Promise<PermissionResponse>;
|
28
|
+
export function hasManyPermissions(body: HasManyPermissionRequest): Promise<HasManyPermissionResponse>;
|
29
|
+
|
30
|
+
}
|
@@ -0,0 +1,52 @@
|
|
1
|
+
declare module "~system/Players" {
|
2
|
+
|
3
|
+
|
4
|
+
export interface Snapshots {
|
5
|
+
face256: string;
|
6
|
+
body: string;
|
7
|
+
}
|
8
|
+
export interface AvatarForUserData {
|
9
|
+
bodyShape: string;
|
10
|
+
skinColor: string;
|
11
|
+
hairColor: string;
|
12
|
+
eyeColor: string;
|
13
|
+
wearables: string[];
|
14
|
+
snapshots: Snapshots | undefined;
|
15
|
+
}
|
16
|
+
export interface UserData {
|
17
|
+
displayName: string;
|
18
|
+
publicKey?: string | undefined;
|
19
|
+
hasConnectedWeb3: boolean;
|
20
|
+
userId: string;
|
21
|
+
version: number;
|
22
|
+
avatar: AvatarForUserData | undefined;
|
23
|
+
}
|
24
|
+
|
25
|
+
// ########### BLOCK
|
26
|
+
|
27
|
+
// importtype { UserData } from "proto/common/UserData.gen";
|
28
|
+
export interface Player {
|
29
|
+
userId: string;
|
30
|
+
}
|
31
|
+
export interface PlayersGetUserDataResponse {
|
32
|
+
data?: UserData | undefined;
|
33
|
+
}
|
34
|
+
export interface PlayerListResponse {
|
35
|
+
players: Player[];
|
36
|
+
}
|
37
|
+
export interface GetPlayerDataRequest {
|
38
|
+
userId: string;
|
39
|
+
}
|
40
|
+
export interface GetPlayersInSceneRequest {
|
41
|
+
}
|
42
|
+
export interface GetConnectedPlayersRequest {
|
43
|
+
}
|
44
|
+
|
45
|
+
// ########### BLOCK
|
46
|
+
|
47
|
+
// importtype { GetPlayerDataRequest, PlayersGetUserDataResponse, GetPlayersInSceneRequest, PlayerListResponse, GetConnectedPlayersRequest } from "proto/Players.gen";
|
48
|
+
export function getPlayerData(body: GetPlayerDataRequest): Promise<PlayersGetUserDataResponse>;
|
49
|
+
export function getPlayersInScene(body: GetPlayersInSceneRequest): Promise<PlayerListResponse>;
|
50
|
+
export function getConnectedPlayers(body: GetConnectedPlayersRequest): Promise<PlayerListResponse>;
|
51
|
+
|
52
|
+
}
|
@@ -0,0 +1,38 @@
|
|
1
|
+
declare module "~system/PortableExperiences" {
|
2
|
+
|
3
|
+
export interface KillRequest {
|
4
|
+
pid: string;
|
5
|
+
}
|
6
|
+
export interface KillResponse {
|
7
|
+
status: boolean;
|
8
|
+
}
|
9
|
+
export interface SpawnRequest {
|
10
|
+
pid: string;
|
11
|
+
}
|
12
|
+
export interface SpawnResponse {
|
13
|
+
pid: string;
|
14
|
+
parentCid: string;
|
15
|
+
}
|
16
|
+
export interface PxRequest {
|
17
|
+
pid: string;
|
18
|
+
}
|
19
|
+
export interface GetPortableExperiencesLoadedRequest {
|
20
|
+
}
|
21
|
+
export interface GetPortableExperiencesLoadedResponse {
|
22
|
+
loaded: SpawnResponse[];
|
23
|
+
}
|
24
|
+
export interface ExitRequest {
|
25
|
+
}
|
26
|
+
export interface ExitResponse {
|
27
|
+
status: boolean;
|
28
|
+
}
|
29
|
+
|
30
|
+
// ########### BLOCK
|
31
|
+
|
32
|
+
// importtype { SpawnRequest, SpawnResponse, KillRequest, KillResponse, ExitRequest, ExitResponse, GetPortableExperiencesLoadedRequest, GetPortableExperiencesLoadedResponse } from "proto/PortableExperiences.gen";
|
33
|
+
export function spawn(body: SpawnRequest): Promise<SpawnResponse>;
|
34
|
+
export function kill(body: KillRequest): Promise<KillResponse>;
|
35
|
+
export function exit(body: ExitRequest): Promise<ExitResponse>;
|
36
|
+
export function getPortableExperiencesLoaded(body: GetPortableExperiencesLoadedRequest): Promise<GetPortableExperiencesLoadedResponse>;
|
37
|
+
|
38
|
+
}
|
@@ -0,0 +1,26 @@
|
|
1
|
+
declare module "~system/RestrictedActions" {
|
2
|
+
|
3
|
+
export interface Vector3 {
|
4
|
+
x: number;
|
5
|
+
y: number;
|
6
|
+
z: number;
|
7
|
+
}
|
8
|
+
export interface MovePlayerToResponse {
|
9
|
+
}
|
10
|
+
export interface MovePlayerToRequest {
|
11
|
+
newRelativePosition: Vector3 | undefined;
|
12
|
+
cameraTarget?: Vector3 | undefined;
|
13
|
+
}
|
14
|
+
export interface TriggerEmoteResponse {
|
15
|
+
}
|
16
|
+
export interface TriggerEmoteRequest {
|
17
|
+
predefinedEmote: string;
|
18
|
+
}
|
19
|
+
|
20
|
+
// ########### BLOCK
|
21
|
+
|
22
|
+
// importtype { MovePlayerToRequest, MovePlayerToResponse, TriggerEmoteRequest, TriggerEmoteResponse } from "proto/RestrictedActions.gen";
|
23
|
+
export function movePlayerTo(body: MovePlayerToRequest): Promise<MovePlayerToResponse>;
|
24
|
+
export function triggerEmote(body: TriggerEmoteRequest): Promise<TriggerEmoteResponse>;
|
25
|
+
|
26
|
+
}
|
@@ -0,0 +1,90 @@
|
|
1
|
+
declare module "~system/SceneStateStorageController" {
|
2
|
+
|
3
|
+
export interface SerializedSceneState {
|
4
|
+
entities: SerializedEntity[];
|
5
|
+
}
|
6
|
+
export interface SerializedComponent {
|
7
|
+
type: number;
|
8
|
+
valueJson: string;
|
9
|
+
}
|
10
|
+
export interface SerializedEntity {
|
11
|
+
id: string;
|
12
|
+
components: SerializedComponent[];
|
13
|
+
}
|
14
|
+
export interface GetProjectManifestRequest {
|
15
|
+
projectId: string;
|
16
|
+
}
|
17
|
+
export interface GetProjectManifestResponse {
|
18
|
+
state?: SerializedSceneState | undefined;
|
19
|
+
}
|
20
|
+
export interface GetProjectManifestByCoordinatesRequest {
|
21
|
+
land: string;
|
22
|
+
}
|
23
|
+
export interface GetProjectManifestByCoordinatesResponse {
|
24
|
+
state?: SerializedSceneState | undefined;
|
25
|
+
}
|
26
|
+
export interface CreateProjectWithCoordsRequest {
|
27
|
+
coordinates: string;
|
28
|
+
}
|
29
|
+
export interface CreateProjectWithCoordsResponse {
|
30
|
+
ok: boolean;
|
31
|
+
}
|
32
|
+
export interface SaveSceneStateRequest {
|
33
|
+
serializedSceneState: SerializedSceneState | undefined;
|
34
|
+
}
|
35
|
+
export interface SaveSceneStateResponse {
|
36
|
+
ok: boolean;
|
37
|
+
error?: string | undefined;
|
38
|
+
}
|
39
|
+
export interface SaveProjectInfoRequest {
|
40
|
+
sceneState: SerializedSceneState | undefined;
|
41
|
+
projectName: string;
|
42
|
+
projectDescription: string;
|
43
|
+
projectScreenshot: string;
|
44
|
+
}
|
45
|
+
export interface SaveProjectInfoResponse {
|
46
|
+
ok: boolean;
|
47
|
+
}
|
48
|
+
export interface PublishSceneStateRequest {
|
49
|
+
sceneId: string;
|
50
|
+
sceneName: string;
|
51
|
+
sceneDescription: string;
|
52
|
+
sceneScreenshot: string;
|
53
|
+
sceneState: SerializedSceneState | undefined;
|
54
|
+
}
|
55
|
+
export interface PublishSceneStateResponse {
|
56
|
+
ok: boolean;
|
57
|
+
error?: string | undefined;
|
58
|
+
}
|
59
|
+
export interface GetStoredStateRequest {
|
60
|
+
sceneId: string;
|
61
|
+
}
|
62
|
+
export interface GetStoredStateResponse {
|
63
|
+
state?: SerializedSceneState | undefined;
|
64
|
+
}
|
65
|
+
export interface CreateProjectFromStateDefinitionRequest {
|
66
|
+
}
|
67
|
+
export interface CreateProjectFromStateDefinitionResponse {
|
68
|
+
state?: SerializedSceneState | undefined;
|
69
|
+
}
|
70
|
+
export interface SendAssetsToRendererRequest {
|
71
|
+
state: SerializedSceneState | undefined;
|
72
|
+
}
|
73
|
+
export interface SendAssetsToRendererResponse {
|
74
|
+
state: string;
|
75
|
+
}
|
76
|
+
|
77
|
+
// ########### BLOCK
|
78
|
+
|
79
|
+
// importtype { GetProjectManifestRequest, GetProjectManifestResponse, GetProjectManifestByCoordinatesRequest, GetProjectManifestByCoordinatesResponse, CreateProjectWithCoordsRequest, CreateProjectWithCoordsResponse, SaveSceneStateRequest, SaveSceneStateResponse, SaveProjectInfoRequest, SaveProjectInfoResponse, PublishSceneStateRequest, PublishSceneStateResponse, GetStoredStateRequest, GetStoredStateResponse, CreateProjectFromStateDefinitionRequest, CreateProjectFromStateDefinitionResponse, SendAssetsToRendererRequest, SendAssetsToRendererResponse } from "proto/SceneStateStorageController.gen";
|
80
|
+
export function getProjectManifest(body: GetProjectManifestRequest): Promise<GetProjectManifestResponse>;
|
81
|
+
export function getProjectManifestByCoordinates(body: GetProjectManifestByCoordinatesRequest): Promise<GetProjectManifestByCoordinatesResponse>;
|
82
|
+
export function createProjectWithCoords(body: CreateProjectWithCoordsRequest): Promise<CreateProjectWithCoordsResponse>;
|
83
|
+
export function saveSceneState(body: SaveSceneStateRequest): Promise<SaveSceneStateResponse>;
|
84
|
+
export function saveProjectInfo(body: SaveProjectInfoRequest): Promise<SaveProjectInfoResponse>;
|
85
|
+
export function publishSceneState(body: PublishSceneStateRequest): Promise<PublishSceneStateResponse>;
|
86
|
+
export function getStoredState(body: GetStoredStateRequest): Promise<GetStoredStateResponse>;
|
87
|
+
export function createProjectFromStateDefinition(body: CreateProjectFromStateDefinitionRequest): Promise<CreateProjectFromStateDefinitionResponse>;
|
88
|
+
export function sendAssetsToRenderer(body: SendAssetsToRendererRequest): Promise<SendAssetsToRendererResponse>;
|
89
|
+
|
90
|
+
}
|