+5
-6
lexicons/ch/indiemusi/alpha/actor/artist.json
+5
-6
lexicons/ch/indiemusi/alpha/actor/artist.json
···
3
"id": "ch.indiemusi.alpha.actor.artist",
4
"defs": {
5
"main": {
6
-
"key": "tid",
7
-
"type": "record",
8
"description": "An artist or band who performs music",
9
"record": {
10
-
"type": "object",
11
-
"required": ["name"],
12
"properties": {
13
"name": {
14
"type": "string",
15
"maxLength": 255
16
}
17
-
}
18
-
}
19
}
20
}
21
}
···
3
"id": "ch.indiemusi.alpha.actor.artist",
4
"defs": {
5
"main": {
6
"description": "An artist or band who performs music",
7
+
"key": "literal:self",
8
"record": {
9
"properties": {
10
"name": {
11
"type": "string",
12
"maxLength": 255
13
}
14
+
},
15
+
"type": "object"
16
+
},
17
+
"type": "record"
18
}
19
}
20
}
+46
lexicons/org/atmosphereconf/profile.json
+46
lexicons/org/atmosphereconf/profile.json
···
···
1
+
{
2
+
"lexicon": 1,
3
+
"id": "org.atmosphereconf.profile",
4
+
"defs": {
5
+
"main": {
6
+
"description": "A declaration of a basic account profile.",
7
+
"key": "literal:self",
8
+
"record": {
9
+
"properties": {
10
+
"avatar": {
11
+
"accept": [
12
+
"image/png",
13
+
"image/jpeg"
14
+
],
15
+
"description": "Small image to be displayed next to posts from account. AKA, 'profile picture'",
16
+
"maxSize": 1000000,
17
+
"type": "blob"
18
+
},
19
+
"createdAt": {
20
+
"format": "datetime",
21
+
"type": "string"
22
+
},
23
+
"description": {
24
+
"description": "Free-form profile description text.",
25
+
"maxGraphemes": 256,
26
+
"maxLength": 2560,
27
+
"type": "string"
28
+
},
29
+
"displayName": {
30
+
"maxGraphemes": 64,
31
+
"maxLength": 640,
32
+
"type": "string"
33
+
},
34
+
"interests": {
35
+
"type": "array",
36
+
"items": {
37
+
"type": "string"
38
+
}
39
+
}
40
+
},
41
+
"type": "object"
42
+
},
43
+
"type": "record"
44
+
}
45
+
}
46
+
}
+14
-11
src/features/actors/handlers.tsx
+14
-11
src/features/actors/handlers.tsx
···
70
71
// TODO: Implement actual publishing owner creation logic here
72
// For now, we'll just simulate success
73
-
console.log("Creating publishing owner:", {
74
-
firstName: firstName?.trim(),
75
-
lastName: lastName?.trim(),
76
-
companyName: companyName?.trim(),
77
-
ipi: ipi?.trim(),
78
-
collectingSociety: collectingSociety?.trim(),
79
-
userId: context.currentUser!.sub, // Safe to use ! because requireAuth ensures currentUser exists
80
-
});
81
82
const oauthClient = new OAuthClient(
83
oauthConfig,
···
100
// collecting_society: collectingSociety?.trim(),
101
// });
102
103
-
const newArtist = await client.ch.indiemusi.alpha.actor.artist.createRecord({
104
-
name: "Hilke"
105
-
})
106
107
return Response.redirect(
108
new URL(
109
"/actors/?success=Publishing owner created successfully",
···
70
71
// TODO: Implement actual publishing owner creation logic here
72
// For now, we'll just simulate success
73
+
// console.log("Creating publishing owner:", {
74
+
// firstName: firstName?.trim(),
75
+
// lastName: lastName?.trim(),
76
+
// companyName: companyName?.trim(),
77
+
// ipi: ipi?.trim(),
78
+
// collectingSociety: collectingSociety?.trim(),
79
+
// userId: context.currentUser!.sub, // Safe to use ! because requireAuth ensures currentUser exists
80
+
// });
81
82
const oauthClient = new OAuthClient(
83
oauthConfig,
···
100
// collecting_society: collectingSociety?.trim(),
101
// });
102
103
+
// const newArtist = await client.ch.indiemusi.alpha.actor.artist.createRecord({
104
+
// name: "Hilke"
105
+
// })
106
107
+
console.log("CLIENT", client);
108
+
const newProfile = await client.org.atmosphereconf.profile.createRecord({ displayName: "Hilke" });
109
+
console.log("NEW PROFILE", newProfile);
110
return Response.redirect(
111
new URL(
112
"/actors/?success=Publishing owner created successfully",
+116
-3
src/generated_client.ts
+116
-3
src/generated_client.ts
···
1
// Generated TypeScript client for AT Protocol records
2
-
// Generated at: 2025-10-12 08:29:02 UTC
3
-
// Lexicons: 23
4
5
/**
6
* @example Usage
···
899
likeCount?: number;
900
}
901
902
export interface ChIndiemusiAlphaRecording {
903
title: string;
904
song?: ChIndiemusiAlphaSong;
···
951
export type ChIndiemusiAlphaSongSortFields = "title" | "iswc";
952
953
export interface ChIndiemusiAlphaActorArtist {
954
-
name: string;
955
}
956
957
export type ChIndiemusiAlphaActorArtistSortFields = "name";
···
1465
}
1466
}
1467
1468
class RecordingAlphaIndiemusiChClient {
1469
private readonly client: SlicesClient;
1470
···
2147
2148
export class AtProtoClient extends SlicesClient {
2149
readonly app: AppClient;
2150
readonly ch: ChClient;
2151
readonly oauth?: OAuthClient | AuthProvider;
2152
···
2157
) {
2158
super(baseUrl, sliceUri, oauthClient);
2159
this.app = new AppClient(this);
2160
this.ch = new ChClient(this);
2161
this.oauth = oauthClient;
2162
}
···
1
// Generated TypeScript client for AT Protocol records
2
+
// Generated at: 2025-10-24 13:07:19 UTC
3
+
// Lexicons: 24
4
5
/**
6
* @example Usage
···
899
likeCount?: number;
900
}
901
902
+
export interface OrgAtmosphereconfProfile {
903
+
/** Small image to be displayed next to posts from account. AKA, 'profile picture' */
904
+
avatar?: BlobRef;
905
+
createdAt?: string;
906
+
/** Free-form profile description text. */
907
+
description?: string;
908
+
displayName?: string;
909
+
interests?: string[];
910
+
}
911
+
912
+
export type OrgAtmosphereconfProfileSortFields =
913
+
| "createdAt"
914
+
| "description"
915
+
| "displayName";
916
+
917
export interface ChIndiemusiAlphaRecording {
918
title: string;
919
song?: ChIndiemusiAlphaSong;
···
966
export type ChIndiemusiAlphaSongSortFields = "title" | "iswc";
967
968
export interface ChIndiemusiAlphaActorArtist {
969
+
name?: string;
970
}
971
972
export type ChIndiemusiAlphaActorArtistSortFields = "name";
···
1480
}
1481
}
1482
1483
+
class ProfileAtmosphereconfOrgClient {
1484
+
private readonly client: SlicesClient;
1485
+
1486
+
constructor(client: SlicesClient) {
1487
+
this.client = client;
1488
+
}
1489
+
1490
+
async getRecords(
1491
+
params?: {
1492
+
limit?: number;
1493
+
cursor?: string;
1494
+
where?: {
1495
+
[K in OrgAtmosphereconfProfileSortFields | IndexedRecordFields]?:
1496
+
WhereCondition;
1497
+
};
1498
+
orWhere?: {
1499
+
[K in OrgAtmosphereconfProfileSortFields | IndexedRecordFields]?:
1500
+
WhereCondition;
1501
+
};
1502
+
sortBy?: SortField<OrgAtmosphereconfProfileSortFields>[];
1503
+
},
1504
+
): Promise<GetRecordsResponse<OrgAtmosphereconfProfile>> {
1505
+
return await this.client.getRecords("org.atmosphereconf.profile", params);
1506
+
}
1507
+
1508
+
async getRecord(
1509
+
params: GetRecordParams,
1510
+
): Promise<RecordResponse<OrgAtmosphereconfProfile>> {
1511
+
return await this.client.getRecord("org.atmosphereconf.profile", params);
1512
+
}
1513
+
1514
+
async countRecords(
1515
+
params?: {
1516
+
limit?: number;
1517
+
cursor?: string;
1518
+
where?: {
1519
+
[K in OrgAtmosphereconfProfileSortFields | IndexedRecordFields]?:
1520
+
WhereCondition;
1521
+
};
1522
+
orWhere?: {
1523
+
[K in OrgAtmosphereconfProfileSortFields | IndexedRecordFields]?:
1524
+
WhereCondition;
1525
+
};
1526
+
sortBy?: SortField<OrgAtmosphereconfProfileSortFields>[];
1527
+
},
1528
+
): Promise<CountRecordsResponse> {
1529
+
return await this.client.countRecords("org.atmosphereconf.profile", params);
1530
+
}
1531
+
1532
+
async createRecord(
1533
+
record: OrgAtmosphereconfProfile,
1534
+
useSelfRkey?: boolean,
1535
+
): Promise<{ uri: string; cid: string }> {
1536
+
return await this.client.createRecord(
1537
+
"org.atmosphereconf.profile",
1538
+
record,
1539
+
useSelfRkey,
1540
+
);
1541
+
}
1542
+
1543
+
async updateRecord(
1544
+
rkey: string,
1545
+
record: OrgAtmosphereconfProfile,
1546
+
): Promise<{ uri: string; cid: string }> {
1547
+
return await this.client.updateRecord(
1548
+
"org.atmosphereconf.profile",
1549
+
rkey,
1550
+
record,
1551
+
);
1552
+
}
1553
+
1554
+
async deleteRecord(rkey: string): Promise<void> {
1555
+
return await this.client.deleteRecord("org.atmosphereconf.profile", rkey);
1556
+
}
1557
+
}
1558
+
1559
+
class AtmosphereconfOrgClient {
1560
+
readonly profile: ProfileAtmosphereconfOrgClient;
1561
+
private readonly client: SlicesClient;
1562
+
1563
+
constructor(client: SlicesClient) {
1564
+
this.client = client;
1565
+
this.profile = new ProfileAtmosphereconfOrgClient(client);
1566
+
}
1567
+
}
1568
+
1569
+
class OrgClient {
1570
+
readonly atmosphereconf: AtmosphereconfOrgClient;
1571
+
private readonly client: SlicesClient;
1572
+
1573
+
constructor(client: SlicesClient) {
1574
+
this.client = client;
1575
+
this.atmosphereconf = new AtmosphereconfOrgClient(client);
1576
+
}
1577
+
}
1578
+
1579
class RecordingAlphaIndiemusiChClient {
1580
private readonly client: SlicesClient;
1581
···
2258
2259
export class AtProtoClient extends SlicesClient {
2260
readonly app: AppClient;
2261
+
readonly org: OrgClient;
2262
readonly ch: ChClient;
2263
readonly oauth?: OAuthClient | AuthProvider;
2264
···
2269
) {
2270
super(baseUrl, sliceUri, oauthClient);
2271
this.app = new AppClient(this);
2272
+
this.org = new OrgClient(this);
2273
this.ch = new ChClient(this);
2274
this.oauth = oauthClient;
2275
}