diff --git a/ydb/docs/en/core/recipes/ydb-sdk/init.md b/ydb/docs/en/core/recipes/ydb-sdk/init.md index ddedf57e77a4..2a95b53a926a 100644 --- a/ydb/docs/en/core/recipes/ydb-sdk/init.md +++ b/ydb/docs/en/core/recipes/ydb-sdk/init.md @@ -140,4 +140,12 @@ Below are examples of the code for connecting to {{ ydb-short-name }} (driver cr $ydb = new Ydb($config); ``` +- Rust + + ```rust + let client = ClientBuilder::new_from_connection_string("grpc://localhost:2136?database=local")? + .with_credentials(AccessTokenCredentials::from("...")) + .client()? + ``` + {% endlist %} diff --git a/ydb/docs/ru/core/recipes/ydb-sdk/init.md b/ydb/docs/ru/core/recipes/ydb-sdk/init.md index 21b281175edb..467563d09575 100644 --- a/ydb/docs/ru/core/recipes/ydb-sdk/init.md +++ b/ydb/docs/ru/core/recipes/ydb-sdk/init.md @@ -164,4 +164,12 @@ $ydb = new Ydb($config); ``` +- Rust + + ```rust + let client = ClientBuilder::new_from_connection_string("grpc://localhost:2136?database=local")? + .with_credentials(AccessTokenCredentials::from("...")) + .client()? + ``` + {% endlist %}