@fedify/fedify 1.1.0-dev.428 → 1.1.0-dev.429

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fedify/fedify",
3
- "version": "1.1.0-dev.428+95c3e7d5",
3
+ "version": "1.1.0-dev.429+15184ca4",
4
4
  "description": "An ActivityPub server framework",
5
5
  "keywords": [
6
6
  "ActivityPub",
@@ -1575,6 +1575,146 @@ export declare class PropertyValue {
1575
1575
  }): Promise<PropertyValue>;
1576
1576
  protected _getCustomInspectProxy(): Record<string, unknown>;
1577
1577
  }
1578
+ /** Means of communicating or interacting with the DID subject or associated
1579
+ * entities via one or more service endpoints. Examples include discovery
1580
+ * services, agent services, social networking services, file storage services,
1581
+ * and verifiable credential repository services.
1582
+ */
1583
+ export declare class DidService {
1584
+ #private;
1585
+ readonly id: URL | null;
1586
+ protected get _documentLoader(): DocumentLoader | undefined;
1587
+ protected get _contextLoader(): DocumentLoader | undefined;
1588
+ /**
1589
+ * The type URI of {@link DidService}: `https://www.w3.org/ns/did#Service`.
1590
+ */
1591
+ static get typeId(): URL;
1592
+ /**
1593
+ * Constructs a new instance of DidService with the given values.
1594
+ * @param values The values to initialize the instance with.
1595
+ * @param options The options to use for initialization.
1596
+ */
1597
+ constructor(values: {
1598
+ id?: URL | null;
1599
+ endpoint?: URL | null;
1600
+ endpoints?: (URL)[];
1601
+ }, { documentLoader, contextLoader, }?: {
1602
+ documentLoader?: DocumentLoader;
1603
+ contextLoader?: DocumentLoader;
1604
+ });
1605
+ /**
1606
+ * Clones this instance, optionally updating it with the given values.
1607
+ * @param values The values to update the clone with.
1608
+ * @options The options to use for cloning.
1609
+ * @returns The cloned instance.
1610
+ */
1611
+ clone(values?: {
1612
+ id?: URL | null;
1613
+ endpoint?: URL | null;
1614
+ endpoints?: (URL)[];
1615
+ }, options?: {
1616
+ documentLoader?: DocumentLoader;
1617
+ contextLoader?: DocumentLoader;
1618
+ }): DidService;
1619
+ /** A network address, such as an HTTP URL, at which services operate on behalf
1620
+ * of a DID subject.
1621
+ */
1622
+ get endpoint(): URL | null;
1623
+ /** A network address, such as an HTTP URL, at which services operate on behalf
1624
+ * of a DID subject.
1625
+ */
1626
+ get endpoints(): (URL)[];
1627
+ /**
1628
+ * Converts this object to a JSON-LD structure.
1629
+ * @param options The options to use.
1630
+ * - `format`: The format of the output: `compact` or
1631
+ `expand`.
1632
+ * - `contextLoader`: The loader for remote JSON-LD contexts.
1633
+ * - `context`: The JSON-LD context to use. Not applicable
1634
+ when `format` is set to `'expand'`.
1635
+ * @returns The JSON-LD representation of this object.
1636
+ */
1637
+ toJsonLd(options?: {
1638
+ format?: "compact" | "expand";
1639
+ contextLoader?: DocumentLoader;
1640
+ context?: string | Record<string, string> | (string | Record<string, string>)[];
1641
+ }): Promise<unknown>;
1642
+ protected isCompactable(): boolean;
1643
+ /**
1644
+ * Converts a JSON-LD structure to an object of this type.
1645
+ * @param json The JSON-LD structure to convert.
1646
+ * @returns The object of this type.
1647
+ * @throws {TypeError} If the given `json` is invalid.
1648
+ */
1649
+ static fromJsonLd(json: unknown, options?: {
1650
+ documentLoader?: DocumentLoader;
1651
+ contextLoader?: DocumentLoader;
1652
+ }): Promise<DidService>;
1653
+ protected _getCustomInspectProxy(): Record<string, unknown>;
1654
+ }
1655
+ /** "Export Actor" service.
1656
+ */
1657
+ export declare class Export extends DidService {
1658
+ #private;
1659
+ /**
1660
+ * The type URI of {@link Export}: `https://w3id.org/fep/9091#Export`.
1661
+ */
1662
+ static get typeId(): URL;
1663
+ /**
1664
+ * Constructs a new instance of Export with the given values.
1665
+ * @param values The values to initialize the instance with.
1666
+ * @param options The options to use for initialization.
1667
+ */
1668
+ constructor(values: {
1669
+ id?: URL | null;
1670
+ endpoint?: URL | null;
1671
+ endpoints?: (URL)[];
1672
+ }, { documentLoader, contextLoader, }?: {
1673
+ documentLoader?: DocumentLoader;
1674
+ contextLoader?: DocumentLoader;
1675
+ });
1676
+ /**
1677
+ * Clones this instance, optionally updating it with the given values.
1678
+ * @param values The values to update the clone with.
1679
+ * @options The options to use for cloning.
1680
+ * @returns The cloned instance.
1681
+ */
1682
+ clone(values?: {
1683
+ id?: URL | null;
1684
+ endpoint?: URL | null;
1685
+ endpoints?: (URL)[];
1686
+ }, options?: {
1687
+ documentLoader?: DocumentLoader;
1688
+ contextLoader?: DocumentLoader;
1689
+ }): Export;
1690
+ /**
1691
+ * Converts this object to a JSON-LD structure.
1692
+ * @param options The options to use.
1693
+ * - `format`: The format of the output: `compact` or
1694
+ `expand`.
1695
+ * - `contextLoader`: The loader for remote JSON-LD contexts.
1696
+ * - `context`: The JSON-LD context to use. Not applicable
1697
+ when `format` is set to `'expand'`.
1698
+ * @returns The JSON-LD representation of this object.
1699
+ */
1700
+ toJsonLd(options?: {
1701
+ format?: "compact" | "expand";
1702
+ contextLoader?: DocumentLoader;
1703
+ context?: string | Record<string, string> | (string | Record<string, string>)[];
1704
+ }): Promise<unknown>;
1705
+ protected isCompactable(): boolean;
1706
+ /**
1707
+ * Converts a JSON-LD structure to an object of this type.
1708
+ * @param json The JSON-LD structure to convert.
1709
+ * @returns The object of this type.
1710
+ * @throws {TypeError} If the given `json` is invalid.
1711
+ */
1712
+ static fromJsonLd(json: unknown, options?: {
1713
+ documentLoader?: DocumentLoader;
1714
+ contextLoader?: DocumentLoader;
1715
+ }): Promise<Export>;
1716
+ protected _getCustomInspectProxy(): Record<string, unknown>;
1717
+ }
1578
1718
  /** A proof that can be added to any activity or object, allowing recipients to
1579
1719
  * verify the identity of the actor and the integrity of the data.
1580
1720
  */
@@ -2460,6 +2600,8 @@ export declare class Application extends Object {
2460
2600
  indexable?: boolean | null;
2461
2601
  alias?: Application | Group | Organization | Person | Service | URL | null;
2462
2602
  aliases?: (Application | Group | Organization | Person | Service | URL)[];
2603
+ service?: DidService | URL | null;
2604
+ services?: (DidService | URL)[];
2463
2605
  cat?: boolean | null;
2464
2606
  }, { documentLoader, contextLoader, }?: {
2465
2607
  documentLoader?: DocumentLoader;
@@ -2540,6 +2682,8 @@ export declare class Application extends Object {
2540
2682
  indexable?: boolean | null;
2541
2683
  alias?: Application | Group | Organization | Person | Service | URL | null;
2542
2684
  aliases?: (Application | Group | Organization | Person | Service | URL)[];
2685
+ service?: DidService | URL | null;
2686
+ services?: (DidService | URL)[];
2543
2687
  cat?: boolean | null;
2544
2688
  }, options?: {
2545
2689
  documentLoader?: DocumentLoader;
@@ -2820,6 +2964,38 @@ export declare class Application extends Object {
2820
2964
  contextLoader?: DocumentLoader;
2821
2965
  suppressError?: boolean;
2822
2966
  }): AsyncIterable<Application | Group | Organization | Person | Service>;
2967
+ /**
2968
+ * Similar to
2969
+ * {@link Application.getService},
2970
+ * but returns its `@id` URL instead of the object itself.
2971
+ */
2972
+ get serviceId(): URL | null;
2973
+ /** Means of communicating or interacting with the DID subject or associated
2974
+ * entities via one or more service endpoints. Examples include discovery
2975
+ * services, agent services, social networking services, file storage services,
2976
+ * and verifiable credential repository services.
2977
+ */
2978
+ getService(options?: {
2979
+ documentLoader?: DocumentLoader;
2980
+ contextLoader?: DocumentLoader;
2981
+ suppressError?: boolean;
2982
+ }): Promise<DidService | null>;
2983
+ /**
2984
+ * Similar to
2985
+ * {@link Application.getServices},
2986
+ * but returns their `@id`s instead of the objects themselves.
2987
+ */
2988
+ get serviceIds(): URL[];
2989
+ /** Means of communicating or interacting with the DID subject or associated
2990
+ * entities via one or more service endpoints. Examples include discovery
2991
+ * services, agent services, social networking services, file storage services,
2992
+ * and verifiable credential repository services.
2993
+ */
2994
+ getServices(options?: {
2995
+ documentLoader?: DocumentLoader;
2996
+ contextLoader?: DocumentLoader;
2997
+ suppressError?: boolean;
2998
+ }): AsyncIterable<DidService>;
2823
2999
  /** Used on actors to indicate that they in some way identify as a cat,
2824
3000
  * expressed as a boolean value. If this property is set to `true`,
2825
3001
  * displaying the actor or their notes will have some special effects
@@ -5679,6 +5855,8 @@ export declare class Group extends Object {
5679
5855
  indexable?: boolean | null;
5680
5856
  alias?: Application | Group | Organization | Person | Service | URL | null;
5681
5857
  aliases?: (Application | Group | Organization | Person | Service | URL)[];
5858
+ service?: DidService | URL | null;
5859
+ services?: (DidService | URL)[];
5682
5860
  cat?: boolean | null;
5683
5861
  }, { documentLoader, contextLoader, }?: {
5684
5862
  documentLoader?: DocumentLoader;
@@ -5759,6 +5937,8 @@ export declare class Group extends Object {
5759
5937
  indexable?: boolean | null;
5760
5938
  alias?: Application | Group | Organization | Person | Service | URL | null;
5761
5939
  aliases?: (Application | Group | Organization | Person | Service | URL)[];
5940
+ service?: DidService | URL | null;
5941
+ services?: (DidService | URL)[];
5762
5942
  cat?: boolean | null;
5763
5943
  }, options?: {
5764
5944
  documentLoader?: DocumentLoader;
@@ -6039,6 +6219,38 @@ export declare class Group extends Object {
6039
6219
  contextLoader?: DocumentLoader;
6040
6220
  suppressError?: boolean;
6041
6221
  }): AsyncIterable<Application | Group | Organization | Person | Service>;
6222
+ /**
6223
+ * Similar to
6224
+ * {@link Group.getService},
6225
+ * but returns its `@id` URL instead of the object itself.
6226
+ */
6227
+ get serviceId(): URL | null;
6228
+ /** Means of communicating or interacting with the DID subject or associated
6229
+ * entities via one or more service endpoints. Examples include discovery
6230
+ * services, agent services, social networking services, file storage services,
6231
+ * and verifiable credential repository services.
6232
+ */
6233
+ getService(options?: {
6234
+ documentLoader?: DocumentLoader;
6235
+ contextLoader?: DocumentLoader;
6236
+ suppressError?: boolean;
6237
+ }): Promise<DidService | null>;
6238
+ /**
6239
+ * Similar to
6240
+ * {@link Group.getServices},
6241
+ * but returns their `@id`s instead of the objects themselves.
6242
+ */
6243
+ get serviceIds(): URL[];
6244
+ /** Means of communicating or interacting with the DID subject or associated
6245
+ * entities via one or more service endpoints. Examples include discovery
6246
+ * services, agent services, social networking services, file storage services,
6247
+ * and verifiable credential repository services.
6248
+ */
6249
+ getServices(options?: {
6250
+ documentLoader?: DocumentLoader;
6251
+ contextLoader?: DocumentLoader;
6252
+ suppressError?: boolean;
6253
+ }): AsyncIterable<DidService>;
6042
6254
  /** Used on actors to indicate that they in some way identify as a cat,
6043
6255
  * expressed as a boolean value. If this property is set to `true`,
6044
6256
  * displaying the actor or their notes will have some special effects
@@ -8359,6 +8571,8 @@ export declare class Organization extends Object {
8359
8571
  indexable?: boolean | null;
8360
8572
  alias?: Application | Group | Organization | Person | Service | URL | null;
8361
8573
  aliases?: (Application | Group | Organization | Person | Service | URL)[];
8574
+ service?: DidService | URL | null;
8575
+ services?: (DidService | URL)[];
8362
8576
  cat?: boolean | null;
8363
8577
  }, { documentLoader, contextLoader, }?: {
8364
8578
  documentLoader?: DocumentLoader;
@@ -8439,6 +8653,8 @@ export declare class Organization extends Object {
8439
8653
  indexable?: boolean | null;
8440
8654
  alias?: Application | Group | Organization | Person | Service | URL | null;
8441
8655
  aliases?: (Application | Group | Organization | Person | Service | URL)[];
8656
+ service?: DidService | URL | null;
8657
+ services?: (DidService | URL)[];
8442
8658
  cat?: boolean | null;
8443
8659
  }, options?: {
8444
8660
  documentLoader?: DocumentLoader;
@@ -8719,6 +8935,38 @@ export declare class Organization extends Object {
8719
8935
  contextLoader?: DocumentLoader;
8720
8936
  suppressError?: boolean;
8721
8937
  }): AsyncIterable<Application | Group | Organization | Person | Service>;
8938
+ /**
8939
+ * Similar to
8940
+ * {@link Organization.getService},
8941
+ * but returns its `@id` URL instead of the object itself.
8942
+ */
8943
+ get serviceId(): URL | null;
8944
+ /** Means of communicating or interacting with the DID subject or associated
8945
+ * entities via one or more service endpoints. Examples include discovery
8946
+ * services, agent services, social networking services, file storage services,
8947
+ * and verifiable credential repository services.
8948
+ */
8949
+ getService(options?: {
8950
+ documentLoader?: DocumentLoader;
8951
+ contextLoader?: DocumentLoader;
8952
+ suppressError?: boolean;
8953
+ }): Promise<DidService | null>;
8954
+ /**
8955
+ * Similar to
8956
+ * {@link Organization.getServices},
8957
+ * but returns their `@id`s instead of the objects themselves.
8958
+ */
8959
+ get serviceIds(): URL[];
8960
+ /** Means of communicating or interacting with the DID subject or associated
8961
+ * entities via one or more service endpoints. Examples include discovery
8962
+ * services, agent services, social networking services, file storage services,
8963
+ * and verifiable credential repository services.
8964
+ */
8965
+ getServices(options?: {
8966
+ documentLoader?: DocumentLoader;
8967
+ contextLoader?: DocumentLoader;
8968
+ suppressError?: boolean;
8969
+ }): AsyncIterable<DidService>;
8722
8970
  /** Used on actors to indicate that they in some way identify as a cat,
8723
8971
  * expressed as a boolean value. If this property is set to `true`,
8724
8972
  * displaying the actor or their notes will have some special effects
@@ -8988,6 +9236,8 @@ export declare class Person extends Object {
8988
9236
  indexable?: boolean | null;
8989
9237
  alias?: Application | Group | Organization | Person | Service | URL | null;
8990
9238
  aliases?: (Application | Group | Organization | Person | Service | URL)[];
9239
+ service?: DidService | URL | null;
9240
+ services?: (DidService | URL)[];
8991
9241
  cat?: boolean | null;
8992
9242
  }, { documentLoader, contextLoader, }?: {
8993
9243
  documentLoader?: DocumentLoader;
@@ -9068,6 +9318,8 @@ export declare class Person extends Object {
9068
9318
  indexable?: boolean | null;
9069
9319
  alias?: Application | Group | Organization | Person | Service | URL | null;
9070
9320
  aliases?: (Application | Group | Organization | Person | Service | URL)[];
9321
+ service?: DidService | URL | null;
9322
+ services?: (DidService | URL)[];
9071
9323
  cat?: boolean | null;
9072
9324
  }, options?: {
9073
9325
  documentLoader?: DocumentLoader;
@@ -9348,6 +9600,38 @@ export declare class Person extends Object {
9348
9600
  contextLoader?: DocumentLoader;
9349
9601
  suppressError?: boolean;
9350
9602
  }): AsyncIterable<Application | Group | Organization | Person | Service>;
9603
+ /**
9604
+ * Similar to
9605
+ * {@link Person.getService},
9606
+ * but returns its `@id` URL instead of the object itself.
9607
+ */
9608
+ get serviceId(): URL | null;
9609
+ /** Means of communicating or interacting with the DID subject or associated
9610
+ * entities via one or more service endpoints. Examples include discovery
9611
+ * services, agent services, social networking services, file storage services,
9612
+ * and verifiable credential repository services.
9613
+ */
9614
+ getService(options?: {
9615
+ documentLoader?: DocumentLoader;
9616
+ contextLoader?: DocumentLoader;
9617
+ suppressError?: boolean;
9618
+ }): Promise<DidService | null>;
9619
+ /**
9620
+ * Similar to
9621
+ * {@link Person.getServices},
9622
+ * but returns their `@id`s instead of the objects themselves.
9623
+ */
9624
+ get serviceIds(): URL[];
9625
+ /** Means of communicating or interacting with the DID subject or associated
9626
+ * entities via one or more service endpoints. Examples include discovery
9627
+ * services, agent services, social networking services, file storage services,
9628
+ * and verifiable credential repository services.
9629
+ */
9630
+ getServices(options?: {
9631
+ documentLoader?: DocumentLoader;
9632
+ contextLoader?: DocumentLoader;
9633
+ suppressError?: boolean;
9634
+ }): AsyncIterable<DidService>;
9351
9635
  /** Used on actors to indicate that they in some way identify as a cat,
9352
9636
  * expressed as a boolean value. If this property is set to `true`,
9353
9637
  * displaying the actor or their notes will have some special effects
@@ -10820,6 +11104,8 @@ export declare class Service extends Object {
10820
11104
  indexable?: boolean | null;
10821
11105
  alias?: Application | Group | Organization | Person | Service | URL | null;
10822
11106
  aliases?: (Application | Group | Organization | Person | Service | URL)[];
11107
+ service?: DidService | URL | null;
11108
+ services?: (DidService | URL)[];
10823
11109
  cat?: boolean | null;
10824
11110
  }, { documentLoader, contextLoader, }?: {
10825
11111
  documentLoader?: DocumentLoader;
@@ -10900,6 +11186,8 @@ export declare class Service extends Object {
10900
11186
  indexable?: boolean | null;
10901
11187
  alias?: Application | Group | Organization | Person | Service | URL | null;
10902
11188
  aliases?: (Application | Group | Organization | Person | Service | URL)[];
11189
+ service?: DidService | URL | null;
11190
+ services?: (DidService | URL)[];
10903
11191
  cat?: boolean | null;
10904
11192
  }, options?: {
10905
11193
  documentLoader?: DocumentLoader;
@@ -11180,6 +11468,38 @@ export declare class Service extends Object {
11180
11468
  contextLoader?: DocumentLoader;
11181
11469
  suppressError?: boolean;
11182
11470
  }): AsyncIterable<Application | Group | Organization | Person | Service>;
11471
+ /**
11472
+ * Similar to
11473
+ * {@link Service.getService},
11474
+ * but returns its `@id` URL instead of the object itself.
11475
+ */
11476
+ get serviceId(): URL | null;
11477
+ /** Means of communicating or interacting with the DID subject or associated
11478
+ * entities via one or more service endpoints. Examples include discovery
11479
+ * services, agent services, social networking services, file storage services,
11480
+ * and verifiable credential repository services.
11481
+ */
11482
+ getService(options?: {
11483
+ documentLoader?: DocumentLoader;
11484
+ contextLoader?: DocumentLoader;
11485
+ suppressError?: boolean;
11486
+ }): Promise<DidService | null>;
11487
+ /**
11488
+ * Similar to
11489
+ * {@link Service.getServices},
11490
+ * but returns their `@id`s instead of the objects themselves.
11491
+ */
11492
+ get serviceIds(): URL[];
11493
+ /** Means of communicating or interacting with the DID subject or associated
11494
+ * entities via one or more service endpoints. Examples include discovery
11495
+ * services, agent services, social networking services, file storage services,
11496
+ * and verifiable credential repository services.
11497
+ */
11498
+ getServices(options?: {
11499
+ documentLoader?: DocumentLoader;
11500
+ contextLoader?: DocumentLoader;
11501
+ suppressError?: boolean;
11502
+ }): AsyncIterable<DidService>;
11183
11503
  /** Used on actors to indicate that they in some way identify as a cat,
11184
11504
  * expressed as a boolean value. If this property is set to `true`,
11185
11505
  * displaying the actor or their notes will have some special effects