Surreal / AsyncSurrealEstablishes a persistent connection to the database.
Method SyntaxSurreal(url) AsyncSurreal(url)
| Arguments | Description | ||
|---|---|---|---|
url required | The url of the database endpoint to connect to. |
Surreal('https://cloud.surrealdb.com') # async AsyncSurreal('https://cloud.surrealdb.com')
You can close the connection using the close() method.