@withmarfa/client 0.0.23 → 0.0.25

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.
Files changed (2) hide show
  1. package/dist/index.d.ts +1 -223
  2. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -461,11 +461,7 @@ interface paths {
461
461
  delete?: never;
462
462
  options?: never;
463
463
  head?: never;
464
- /**
465
- * Merge tags into an item
466
- * @description Merges the tags you send into the item's tags as a set union, and returns its metadata. Existing tags stay. To replace them, use `PUT /items/{id}/metadata`.
467
- */
468
- patch: operations["updateItemMetadata"];
464
+ patch?: never;
469
465
  trace?: never;
470
466
  };
471
467
  "/items/{id}/tags": {
@@ -10640,224 +10636,6 @@ interface operations {
10640
10636
  };
10641
10637
  };
10642
10638
  };
10643
- updateItemMetadata: {
10644
- parameters: {
10645
- query?: never;
10646
- header?: {
10647
- /** @description A unique key that makes the request safe to retry. If you send the same request with the same key again, Marfa returns the first response and doesn't write again. A key belongs to the credential that sends it. */
10648
- "Idempotency-Key"?: string;
10649
- /** @description The ID of the instance you expect, as `GET /` returns it. If another instance answers at this address, Marfa returns `409 instance_changed` and doesn't write. Leave it out to send the request to whichever instance answers. */
10650
- "X-Marfa-Instance-Id"?: string;
10651
- };
10652
- path: {
10653
- /** @description The ID of the item. */
10654
- id: string;
10655
- };
10656
- cookie?: never;
10657
- };
10658
- requestBody: {
10659
- content: {
10660
- "application/json": {
10661
- /** @description Tags to add: each up to 128 characters. The item can hold at most 100. */
10662
- tags?: string[];
10663
- };
10664
- };
10665
- };
10666
- responses: {
10667
- /** @description Returns the item's metadata with the merged tags. */
10668
- 200: {
10669
- headers: {
10670
- "X-Marfa-Contract": components["headers"]["X-Marfa-Contract"];
10671
- "X-Request-ID": components["headers"]["X-Request-ID"];
10672
- "X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
10673
- "X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
10674
- "X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
10675
- "Idempotency-Replayed": components["headers"]["Idempotency-Replayed"];
10676
- [name: string]: unknown;
10677
- };
10678
- content: {
10679
- "application/json": components["schemas"]["MetadataResponse"];
10680
- };
10681
- };
10682
- /**
10683
- * @description - `validation_error`: `tags` is not a list of valid tags or the item would hold more than 100, or the body has a field this endpoint doesn't take.
10684
- * - `invalid_id`: the ID is not a valid item ID.
10685
- */
10686
- 400: {
10687
- headers: {
10688
- "X-Marfa-Contract": components["headers"]["X-Marfa-Contract"];
10689
- "X-Request-ID": components["headers"]["X-Request-ID"];
10690
- "X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
10691
- "X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
10692
- "X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
10693
- "X-Error-Code": components["headers"]["X-Error-Code"];
10694
- "Idempotency-Replayed": components["headers"]["Idempotency-Replayed"];
10695
- [name: string]: unknown;
10696
- };
10697
- content: {
10698
- "application/json": components["schemas"]["InvalidIdOrMissingRequiredFieldOrValidationErrorRefusal"];
10699
- };
10700
- };
10701
- /** @description `unauthorized`: the request has no credential, or its credential is not valid. */
10702
- 401: {
10703
- headers: {
10704
- "X-Marfa-Contract": components["headers"]["X-Marfa-Contract"];
10705
- "X-Request-ID": components["headers"]["X-Request-ID"];
10706
- "X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
10707
- "X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
10708
- "X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
10709
- "X-Error-Code": components["headers"]["X-Error-Code"];
10710
- [name: string]: unknown;
10711
- };
10712
- content: {
10713
- "application/json": components["schemas"]["UnauthorizedRefusal"];
10714
- };
10715
- };
10716
- /** @description - `type_not_permitted`: you can read the item's type but don't have write on it, or your credential reaches no type. `details.grant` names the missing grant. */
10717
- 403: {
10718
- headers: {
10719
- "X-Marfa-Contract": components["headers"]["X-Marfa-Contract"];
10720
- "X-Request-ID": components["headers"]["X-Request-ID"];
10721
- "X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
10722
- "X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
10723
- "X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
10724
- "X-Error-Code": components["headers"]["X-Error-Code"];
10725
- [name: string]: unknown;
10726
- };
10727
- content: {
10728
- "application/json": components["schemas"]["TypeNotPermittedRefusal"];
10729
- };
10730
- };
10731
- /** @description - `item_not_found`: no item has this ID, or its type is one you can't read. If the item is in the trash and you can read its type, `details.trashed` is `true`. */
10732
- 404: {
10733
- headers: {
10734
- "X-Marfa-Contract": components["headers"]["X-Marfa-Contract"];
10735
- "X-Request-ID": components["headers"]["X-Request-ID"];
10736
- "X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
10737
- "X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
10738
- "X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
10739
- "X-Error-Code": components["headers"]["X-Error-Code"];
10740
- "Idempotency-Replayed": components["headers"]["Idempotency-Replayed"];
10741
- [name: string]: unknown;
10742
- };
10743
- content: {
10744
- "application/json": components["schemas"]["ItemNotFoundRefusal"];
10745
- };
10746
- };
10747
- /** @description `instance_changed`: `X-Marfa-Instance-Id` names another instance. Nothing is written. Rebuild the working copy from the instance at this address. */
10748
- 409: {
10749
- headers: {
10750
- "X-Marfa-Contract": components["headers"]["X-Marfa-Contract"];
10751
- "X-Request-ID": components["headers"]["X-Request-ID"];
10752
- "X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
10753
- "X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
10754
- "X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
10755
- "X-Error-Code": components["headers"]["X-Error-Code"];
10756
- "Idempotency-Replayed": components["headers"]["Idempotency-Replayed"];
10757
- [name: string]: unknown;
10758
- };
10759
- content: {
10760
- "application/json": components["schemas"]["InstanceChangedRefusal"] | components["schemas"]["IdempotencyKeyInFlightRefusal"];
10761
- };
10762
- };
10763
- /** @description `request_too_large`: the request body is larger than this instance accepts. */
10764
- 413: {
10765
- headers: {
10766
- "X-Marfa-Contract": components["headers"]["X-Marfa-Contract"];
10767
- "X-Request-ID": components["headers"]["X-Request-ID"];
10768
- "X-Error-Code": components["headers"]["X-Error-Code"];
10769
- [name: string]: unknown;
10770
- };
10771
- content: {
10772
- "application/json": components["schemas"]["RequestTooLargeRefusal"];
10773
- };
10774
- };
10775
- /**
10776
- * @description - `idempotency_key_reused`: the key was first used for a different request. Nothing is written.
10777
- * - `idempotency_result_not_retained`: the first response was too large to keep, so Marfa can't replay it. The write isn't repeated.
10778
- */
10779
- 422: {
10780
- headers: {
10781
- "X-Marfa-Contract": components["headers"]["X-Marfa-Contract"];
10782
- "X-Request-ID": components["headers"]["X-Request-ID"];
10783
- "X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
10784
- "X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
10785
- "X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
10786
- "X-Error-Code": components["headers"]["X-Error-Code"];
10787
- "Idempotency-Replayed": components["headers"]["Idempotency-Replayed"];
10788
- [name: string]: unknown;
10789
- };
10790
- content: {
10791
- "application/json": components["schemas"]["IdempotencyKeyReusedOrIdempotencyResultNotRetainedRefusal"];
10792
- };
10793
- };
10794
- /** @description `rate_limited`: you sent too many requests. Wait for the number of seconds in `Retry-After`, then try again. */
10795
- 429: {
10796
- headers: {
10797
- "X-Marfa-Contract": components["headers"]["X-Marfa-Contract"];
10798
- "X-Request-ID": components["headers"]["X-Request-ID"];
10799
- "X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
10800
- "X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
10801
- "X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
10802
- "X-Error-Code": components["headers"]["X-Error-Code"];
10803
- "Retry-After": components["headers"]["Retry-After"];
10804
- "Idempotency-Replayed": components["headers"]["Idempotency-Replayed"];
10805
- [name: string]: unknown;
10806
- };
10807
- content: {
10808
- "application/json": components["schemas"]["RateLimitedRefusal"];
10809
- };
10810
- };
10811
- /** @description `internal_error`: Marfa failed in a way it didn't expect, and the request may not have completed. Read what you changed before you repeat a write. */
10812
- 500: {
10813
- headers: {
10814
- "X-Marfa-Contract": components["headers"]["X-Marfa-Contract"];
10815
- "X-Request-ID": components["headers"]["X-Request-ID"];
10816
- "X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
10817
- "X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
10818
- "X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
10819
- "X-Error-Code": components["headers"]["X-Error-Code"];
10820
- "Idempotency-Replayed": components["headers"]["Idempotency-Replayed"];
10821
- [name: string]: unknown;
10822
- };
10823
- content: {
10824
- "application/json": components["schemas"]["InternalErrorRefusal"];
10825
- };
10826
- };
10827
- /** @description `write_contention`: the database was busy, and Marfa couldn't complete the request in time. Nothing changed. Try the request again. */
10828
- 503: {
10829
- headers: {
10830
- "X-Marfa-Contract": components["headers"]["X-Marfa-Contract"];
10831
- "X-Request-ID": components["headers"]["X-Request-ID"];
10832
- "X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
10833
- "X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
10834
- "X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
10835
- "X-Error-Code": components["headers"]["X-Error-Code"];
10836
- "Idempotency-Replayed": components["headers"]["Idempotency-Replayed"];
10837
- [name: string]: unknown;
10838
- };
10839
- content: {
10840
- "application/json": components["schemas"]["WriteContentionRefusal"];
10841
- };
10842
- };
10843
- /** @description `insufficient_storage`: the disk that holds the instance's data has no room for the request, or the request would leave less free than the instance keeps in reserve. Nothing changed, unless `details.write_outcome` is `unknown`, which means the write may have landed: read what you changed before you repeat it. Free space on the disk, then try the request again. */
10844
- 507: {
10845
- headers: {
10846
- "X-Marfa-Contract": components["headers"]["X-Marfa-Contract"];
10847
- "X-Request-ID": components["headers"]["X-Request-ID"];
10848
- "X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
10849
- "X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
10850
- "X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
10851
- "X-Error-Code": components["headers"]["X-Error-Code"];
10852
- "Idempotency-Replayed": components["headers"]["Idempotency-Replayed"];
10853
- [name: string]: unknown;
10854
- };
10855
- content: {
10856
- "application/json": components["schemas"]["InsufficientStorageRefusal"];
10857
- };
10858
- };
10859
- };
10860
- };
10861
10639
  addItemTags: {
10862
10640
  parameters: {
10863
10641
  query?: never;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@withmarfa/client",
3
- "version": "0.0.23",
3
+ "version": "0.0.25",
4
4
  "license": "Apache-2.0",
5
5
  "repository": {
6
6
  "type": "git",