@authhero/adapter-interfaces 0.1.3 → 0.2.1

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/README.md +11 -0
  2. package/package.json +6 -1
package/README.md CHANGED
@@ -1,3 +1,14 @@
1
1
  # @authhero/adapter-interfaces
2
2
 
3
3
  This package provides a set of interfaces used for creating adapters for AuthHero. Adapters are used to connect AuthHero to various services, such as databases, email services, and more.
4
+
5
+ ## Database adapters
6
+
7
+ The database adapters follow these rules:
8
+
9
+ - The created_at and modified_at fields are handled by the adapter when creating or updating a record.
10
+ - The tenant_id field is not part of the entities sent to the adapter.
11
+ - The entity id is passed to the adapter.
12
+ - The adapter can pass objects such as authParams. These objects will typically be flattened as part of the adapter.
13
+ - The types used in the adapters should be inferred from zod schemas to ensure type safety at runtime.
14
+ - The id column an and entity should start with the entity name, e.g. user_id for the user entity.
package/package.json CHANGED
@@ -1,12 +1,17 @@
1
1
  {
2
2
  "name": "@authhero/adapter-interfaces",
3
3
  "private": false,
4
+ "publishConfig": {
5
+ "access": "public",
6
+ "registry": "https://registry.npmjs.org/",
7
+ "tag": "latest"
8
+ },
4
9
  "homepage": "https://authhero.net",
5
10
  "repository": {
6
11
  "type": "git",
7
12
  "url": "https://github.com/markusahlstrand/authhero"
8
13
  },
9
- "version": "0.1.3",
14
+ "version": "0.2.1",
10
15
  "files": [
11
16
  "dist"
12
17
  ],