File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed
Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -792,3 +792,17 @@ landing_getting_started_1: |-
792792 Movie { "id": "5".to_string(), "title": "Moana".to_string() },
793793 Movie { "id": "6".to_string(), "title": "Philadelphia".to_string() }
794794 ], Some("reference_number")).await.unwrap();
795+ tenant_token_guide_generate_sdk_1 : |-
796+ let api_key = "B5KdX2MY2jV6EXfUs6scSfmC...";
797+ let expires_at = time::macros::datetime!(2025 - 12 - 20 00:00:00 UTC);
798+ let search_rules = json!({ "patient_medical_records": { "filter": "user_id = 1" } });
799+
800+ let token = client.generate_tenant_token(search_rules, api_key, expires_at).unwrap();
801+ tenant_token_guide_search_sdk_1 : |-
802+ let front_end_client = Client::new("http://127.0.0.1:7700", token);
803+ let results: SearchResults<Patient> = front_end_client.index("patient_medical_records")
804+ .search()
805+ .with_query("blood test")
806+ .execute()
807+ .await
808+ .unwrap();
You can’t perform that action at this time.
0 commit comments