Skip to content

Commit e8b797f

Browse files
committed
chore: add frontmatter
1 parent e4c9a3d commit e8b797f

32 files changed

Lines changed: 273 additions & 16 deletions

sqlite-cloud/sqlite-ai/sqlite-sync/api-reference/cloudsync_begin_alter.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
---
2+
title: SQLite-Sync API Reference - cloudsync_begin_alter
3+
description: SQLite Sync is a multi-platform extension that brings a true local-first experience to your applications with minimal effort.
4+
category: platform
5+
status: publish
6+
slug: sqlite-sync-api-cloudsync-begin-alter
7+
---
8+
19
### `cloudsync_begin_alter(table_name)`
210

311
**Description:** Prepares a synchronized table for schema changes. This function must be called before altering the table. Failure to use `cloudsync_begin_alter` and `cloudsync_commit_alter` can lead to synchronization errors and data divergence.

sqlite-cloud/sqlite-ai/sqlite-sync/api-reference/cloudsync_cleanup.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
---
2+
title: SQLite-Sync API Reference - cloudsync_cleanup
3+
description: SQLite Sync is a multi-platform extension that brings a true local-first experience to your applications with minimal effort.
4+
category: platform
5+
status: publish
6+
slug: sqlite-sync-api-cloudsync-cleanup
7+
---
8+
19
### `cloudsync_cleanup(table_name)`
210

311
**Description:** Removes the `sqlite-sync` synchronization mechanism from a specified table or all tables. This operation drops the associated `_cloudsync` metadata table and removes triggers from the target table(s). Use this function when synchronization is no longer desired for a table.
@@ -14,4 +22,4 @@
1422
-- Clean up a single table
1523
SELECT cloudsync_cleanup('my_table');
1624

17-
```
25+
```

sqlite-cloud/sqlite-ai/sqlite-sync/api-reference/cloudsync_commit_alter.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
---
2+
title: SQLite-Sync API Reference - cloudsync_commit_alter
3+
description: SQLite Sync is a multi-platform extension that brings a true local-first experience to your applications with minimal effort.
4+
category: platform
5+
status: publish
6+
slug: sqlite-sync-api-cloudsync-commit-alter
7+
---
8+
19
### `cloudsync_commit_alter(table_name)`
210

311
**Description:** Finalizes schema changes for a synchronized table. This function must be called after altering the table's schema, completing the process initiated by `cloudsync_begin_alter` and ensuring CRDT data consistency.

sqlite-cloud/sqlite-ai/sqlite-sync/api-reference/cloudsync_db_version.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
---
2+
title: SQLite-Sync API Reference - cloudsync_db_version
3+
description: SQLite Sync is a multi-platform extension that brings a true local-first experience to your applications with minimal effort.
4+
category: platform
5+
status: publish
6+
slug: sqlite-sync-api-cloudsync-db-version
7+
---
8+
19
### `cloudsync_db_version()`
210

311
**Description:** Returns the current database version.

sqlite-cloud/sqlite-ai/sqlite-sync/api-reference/cloudsync_disable.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
---
2+
title: SQLite-Sync API Reference - cloudsync_disable
3+
description: SQLite Sync is a multi-platform extension that brings a true local-first experience to your applications with minimal effort.
4+
category: platform
5+
status: publish
6+
slug: sqlite-sync-api-cloudsync-disable
7+
---
8+
19
### `cloudsync_disable(table_name)`
210

311
**Description:** Disables synchronization for the specified table.

sqlite-cloud/sqlite-ai/sqlite-sync/api-reference/cloudsync_enable.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
---
2+
title: SQLite-Sync API Reference - cloudsync_enable
3+
description: SQLite Sync is a multi-platform extension that brings a true local-first experience to your applications with minimal effort.
4+
category: platform
5+
status: publish
6+
slug: sqlite-sync-api-cloudsync-enable
7+
---
8+
19
### `cloudsync_enable(table_name)`
210

311
**Description:** Enables synchronization for the specified table.

sqlite-cloud/sqlite-ai/sqlite-sync/api-reference/cloudsync_init.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
---
2+
title: SQLite-Sync API Reference - cloudsync_init
3+
description: SQLite Sync is a multi-platform extension that brings a true local-first experience to your applications with minimal effort.
4+
category: platform
5+
status: publish
6+
slug: sqlite-sync-api-cloudsync-init
7+
---
8+
19
### `cloudsync_init(table_name, [crdt_algo], [force])`
210

311
**Description:** Initializes a table for `sqlite-sync` synchronization. This function is idempotent and needs to be called only once per table on each site; configurations are stored in the database and automatically loaded with the extension.
@@ -18,7 +26,7 @@ When designing your database schema for SQLite Sync, follow these essential requ
1826
- **Foreign Key Compatibility**: Be aware of potential conflicts during CRDT merge operations and RLS policy interactions.
1927
- **Trigger Compatibility**: Triggers may cause duplicate operations or be called multiple times due to column-by-column processing.
2028

21-
For comprehensive guidelines, see the [Database Schema Recommendations](https://github.com/sqliteai/sqlite-sync/blob/main/README.md#database-schema-recommendations) section.
29+
For comprehensive guidelines, see the [Database Schema Recommendations](/docs/sqlite-sync-best-practices) section.
2230

2331
The function supports three overloads:
2432

sqlite-cloud/sqlite-ai/sqlite-sync/api-reference/cloudsync_is_enabled.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
---
2+
title: SQLite-Sync API Reference - cloudsync_is_enabled
3+
description: SQLite Sync is a multi-platform extension that brings a true local-first experience to your applications with minimal effort.
4+
category: platform
5+
status: publish
6+
slug: sqlite-sync-api-cloudsync-is-enabled
7+
---
8+
19
### `cloudsync_is_enabled(table_name)`
210

311
**Description:** Checks if synchronization is enabled for the specified table.

sqlite-cloud/sqlite-ai/sqlite-sync/api-reference/cloudsync_network_check_changes.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,19 @@
1+
---
2+
title: SQLite-Sync API Reference - cloudsync_network_check_changes
3+
description: SQLite Sync is a multi-platform extension that brings a true local-first experience to your applications with minimal effort.
4+
category: platform
5+
status: publish
6+
slug: sqlite-sync-api-cloudsync-network-check-changes
7+
---
8+
19
### `cloudsync_network_check_changes()`
210

311
**Description:** Checks the remote server for new changes and applies them to the local database.
412

513
If a package of new changes is already available for the local site, the server returns it immediately, and the changes are applied. If no package is ready, the server returns an empty response and starts an asynchronous process to prepare a new package. This new package can be retrieved with a subsequent call to this function.
614

715
This function is designed to be called periodically to keep the local database in sync.
8-
To force an update and wait for changes (with a timeout), use [`cloudsync_network_sync(wait_ms, max_retries)`].
16+
To force an update and wait for changes (with a timeout), use `cloudsync_network_sync(wait_ms, max_retries)`.
917

1018
If the network is misconfigured or the remote server is unreachable, the function returns an error.
1119
On success, it returns `SQLITE_OK`, and the return value indicates how many changes were downloaded and applied.

sqlite-cloud/sqlite-ai/sqlite-sync/api-reference/cloudsync_network_cleanup.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
---
2+
title: SQLite-Sync API Reference - cloudsync_network_cleanup
3+
description: SQLite Sync is a multi-platform extension that brings a true local-first experience to your applications with minimal effort.
4+
category: platform
5+
status: publish
6+
slug: sqlite-sync-api-cloudsync-network-cleanup
7+
---
8+
19
### `cloudsync_network_cleanup()`
210

311
**Description:** Cleans up the `sqlite-sync` network component, releasing all resources allocated by `cloudsync_network_init` (memory, cURL handles).

0 commit comments

Comments
 (0)