Skip to content

fix(dependency): update dependency pocketbase to ^0.26.0#238

Open
renovate[bot] wants to merge 1 commit intomainfrom
renovate/pocketbase-0.x
Open

fix(dependency): update dependency pocketbase to ^0.26.0#238
renovate[bot] wants to merge 1 commit intomainfrom
renovate/pocketbase-0.x

Conversation

@renovate
Copy link
Copy Markdown
Contributor

@renovate renovate bot commented Dec 8, 2024

This PR contains the following updates:

Package Change Age Confidence
pocketbase ^0.21.1^0.26.0 age confidence

Release Notes

pocketbase/js-sdk (pocketbase)

v0.26.8

Compare Source

  • Properly reject the authWithOAuth2() Promise when manually calling pb.cancelRequest(requestKey) (previously the manual cancellation didn't account for the waiting realtime subscription).

v0.26.7

Compare Source

  • Normalized pb.files.getURL() to serialize the URL query params in the same manner as in the fetch methods (e.g. passing null or undefined as query param value will be skipped from the generated URL).

v0.26.6

Compare Source

  • Fixed abort request error detection on React Native Android/iOS (#​361; thanks @​nathanstitt).

  • Updated the default getFullList() batch size to 1000 for consistency with the Dart SDK and the v0.23+ API limits.

v0.26.5

Compare Source

  • Fixed abort request error detection on Safari introduced with the previous release because it seems to throw DOMException.SyntaxError on response.json() failure (#pocketbase/pocketbase#7369).

v0.26.4

Compare Source

  • Catch aborted request error during response.json() failure (e.g. in case of tcp connection reset) and rethrow it as normalized ClientResponseError.isAbort=true error.

v0.26.3

Compare Source

v0.26.2

Compare Source

  • Allow body object without constructor (#​352).

v0.26.1

Compare Source

  • Set the cause property of ClientResponseError to the original thrown error/data for easier debugging (#​349; thanks @​shish).

v0.26.0

Compare Source

  • Ignore undefined properties when submitting an object that has Blob/File fields (which is under the hood converted to FormData)
    for consistency with how JSON.stringify works (see pocketbase#6731).

v0.25.2

Compare Source

  • Removed unnecessary checks in serializeQueryParams and added automated tests.

v0.25.1

Compare Source

  • Ignore query parameters with undefined value (#​330).

v0.25.0

Compare Source

  • Added pb.crons service to interact with the cron Web APIs.

v0.24.0

Compare Source

  • Added support for assigning FormData as body to individual batch requests (pocketbase#6145).

v0.23.0

Compare Source

  • Added optional pb.realtime.onDisconnect hook function.
    Note that the realtime client autoreconnect on its own and this hook is useful only for the cases where you want to apply a special behavior on server error or after closing the realtime connection.

v0.22.1

Compare Source

  • Fixed old pb.authStore.isAdmin/pb.authStore.isAuthRecord and marked them as deprecated in favour of pb.authStore.isSuperuser (#​323).
    Note that with PocketBase v0.23.0 superusers are converted to a system auth collection so you can always simply check the value of pb.authStore.record?.collectionName.

v0.22.0

Compare Source

⚠️ This release introduces some breaking changes and works only with PocketBase v0.23.0+.

  • Added support for sending batch/transactional create/updated/delete/upsert requests with the new batch Web APIs.

    const batch = pb.createBatch();
    
    batch.collection("example1").create({ ... });
    batch.collection("example2").update("RECORD_ID", { ... });
    batch.collection("example3").delete("RECORD_ID");
    batch.collection("example4").upsert({ ... });
    
    const result = await batch.send();
  • Added support for authenticating with OTP (email code):

    const result = await pb.collection("users").requestOTP("test@example.com");
    
    // ... show a modal for users to check their email and to enter the received code ...
    
    await pb.collection("users").authWithOTP(result.otpId, "EMAIL_CODE");

    Note that PocketBase v0.23.0 comes also with Multi-factor authentication (MFA) support.
    When enabled from the dashboard, the first auth attempt will result in 401 response and a mfaId response,
    that will have to be submitted with the second auth request. For example:

    try {
      await pb.collection("users").authWithPassword("test@example.com", "1234567890");
    } catch (err) {
      const mfaId = err.response?.mfaId;
      if (!mfaId) {
        throw err; // not mfa -> rethrow
      }
    
      // the user needs to authenticate again with another auth method, for example OTP
      const result = await pb.collection("users").requestOTP("test@example.com");
      // ... show a modal for users to check their email and to enter the received code ...
      await pb.collection("users").authWithOTP(result.otpId, "EMAIL_CODE", { "mfaId": mfaId });
    }
  • Added new pb.collection("users").impersonate("RECORD_ID") method for superusers.
    It authenticates with the specified record id and returns a new client with the impersonated auth state loaded in a memory store.

    // authenticate as superusers (with v0.23.0 admins is converted to a special system auth collection "_superusers"):
    await pb.collection("_superusers").authWithPassword("test@example.com", "1234567890");
    
    // impersonate
    const impersonateClient = pb.collection("users").impersonate("USER_RECORD_ID", 3600 /* optional token duration in seconds */)
    
    // log the impersonate token and user data
    console.log(impersonateClient.authStore.token);
    console.log(impersonateClient.authStore.record);
    
    // send requests as the impersonated user
    impersonateClient.collection("example").getFullList();
  • Added new pb.collections.getScaffolds() method to retrieve a type indexed map with the collection models (base, auth, view) loaded with their defaults.

  • Added new pb.collections.truncate(idOrName) to delete all records associated with the specified collection.

  • Added the submitted fetch options as 3rd last argument in the pb.afterSend hook.

  • Instead of replacing the entire pb.authStore.record, on auth record update we now only replace the available returned response record data (pocketbase#5638).

  • ⚠️ Admins are converted to _superusers auth collection and there is no longer AdminService and AdminModel types.
    pb.admins is soft-deprecated and aliased to pb.collection("_superusers").

    // before   ->  after
    pb.admins.* ->  pb.collection("_superusers").*
  • ⚠️ pb.authStore.model is soft-deprecated and superseded by pb.authStore.record.

  • ⚠️ Soft-deprecated the OAuth2 success auth meta.avatarUrl response field in favour of meta.avatarURL for consistency with the Go conventions.

  • ⚠️ Changed AuthMethodsList inerface fields to accomodate the new auth methods and listAuthMethods() response.

    {
      "mfa": {
        "duration": 100,
        "enabled": true
      },
      "otp": {
        "duration": 0,
        "enabled": false
      },
      "password": {
        "enabled": true,
        "identityFields": ["email", "username"]
      },
      "oauth2": {
        "enabled": true,
        "providers": [{"name": "gitlab", ...}, {"name": "google", ...}]
      }
    }
    
  • ⚠️ Require specifying collection id or name when sending test email because the email templates can be changed per collection.

    // old
    pb.settings.testEmail(email, "verification")
    
    // new
    pb.settings.testEmail("users", email, "verification")
  • ⚠️ Soft-deprecated and aliased *Url() -> *URL() methods for consistency with other similar native JS APIs and the accepted Go conventions.
    The old methods still works but you may get a console warning to replace them because they will be removed in the future.

    pb.baseUrl                  -> pb.baseURL
    pb.buildUrl()               -> pb.buildURL()
    pb.files.getUrl()           -> pb.files.getURL()
    pb.backups.getDownloadUrl() -> pb.backups.getDownloadURL()
  • ⚠️ Renamed CollectionModel.schema to CollectionModel.fields.

  • ⚠️ Renamed type SchemaField to CollectionField.

v0.21.5

Compare Source

  • Shallow copy the realtime subscribe options argument for consistency with the other methods (#​308).

v0.21.4

Compare Source

  • Fixed the requestKey handling in authWithOAuth2({...}) to allow manually cancelling the entire OAuth2 pending request flow using pb.cancelRequest(requestKey).
    Due to the window.close caveats note that the OAuth2 popup window may still remain open depending on which stage of the OAuth2 flow the cancellation has been invoked.

v0.21.3

Compare Source

v0.21.2

Compare Source

  • Exported HealthService types (#​289).

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot added the dependencies label Dec 8, 2024
@renovate renovate bot force-pushed the renovate/pocketbase-0.x branch from ac0762f to 5b2692d Compare December 15, 2024 19:04
@renovate renovate bot changed the title fix(dependency): update dependency pocketbase to ^0.22.0 fix(dependency): update dependency pocketbase to ^0.23.0 Dec 15, 2024
@renovate renovate bot force-pushed the renovate/pocketbase-0.x branch from 5b2692d to 2035c9e Compare December 19, 2024 23:40
@renovate renovate bot changed the title fix(dependency): update dependency pocketbase to ^0.23.0 fix(dependency): update dependency pocketbase to ^0.24.0 Dec 19, 2024
@renovate renovate bot force-pushed the renovate/pocketbase-0.x branch from 2035c9e to 5622a09 Compare January 1, 2025 16:23
@renovate renovate bot changed the title fix(dependency): update dependency pocketbase to ^0.24.0 fix(dependency): update dependency pocketbase to ^0.25.0 Jan 1, 2025
@renovate renovate bot force-pushed the renovate/pocketbase-0.x branch from 5622a09 to a233ea7 Compare February 24, 2025 07:10
@renovate renovate bot force-pushed the renovate/pocketbase-0.x branch from a233ea7 to 31cd84d Compare April 17, 2025 12:35
@renovate renovate bot changed the title fix(dependency): update dependency pocketbase to ^0.25.0 fix(dependency): update dependency pocketbase to ^0.26.0 Apr 17, 2025
@renovate renovate bot force-pushed the renovate/pocketbase-0.x branch from 31cd84d to bc855d0 Compare July 23, 2025 18:32
@renovate renovate bot force-pushed the renovate/pocketbase-0.x branch from bc855d0 to 5d2c183 Compare October 26, 2025 10:00
@renovate renovate bot force-pushed the renovate/pocketbase-0.x branch 2 times, most recently from 4dadcac to f9ce0f7 Compare December 4, 2025 14:02
@renovate renovate bot force-pushed the renovate/pocketbase-0.x branch 2 times, most recently from 9997c09 to f0b6b6d Compare January 19, 2026 18:45
@renovate renovate bot force-pushed the renovate/pocketbase-0.x branch 2 times, most recently from 4720144 to c701ab1 Compare January 29, 2026 20:55
@renovate renovate bot force-pushed the renovate/pocketbase-0.x branch from c701ab1 to b48c4c2 Compare February 12, 2026 11:35
@renovate renovate bot force-pushed the renovate/pocketbase-0.x branch from b48c4c2 to 5a1672c Compare March 5, 2026 19:16
@renovate renovate bot force-pushed the renovate/pocketbase-0.x branch from 5a1672c to bb978dd Compare March 13, 2026 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants