@@ -34,7 +34,7 @@ stagehand = Stagehand::Client.new(
3434 model_api_key: ENV [" MODEL_API_KEY" ] # This is the default and can be omitted
3535)
3636
37- response = stagehand.sessions.act(" 182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e " , input: " click the first link on the page" )
37+ response = stagehand.sessions.act(" 00000000-your-session-id-000000000000 " , input: " click the first link on the page" )
3838
3939puts (response.actions)
4040```
@@ -46,8 +46,8 @@ When the library is unable to connect to the API, or if the API returns a non-su
4646``` ruby
4747begin
4848 session = stagehand.sessions.start(
49- browserbase_api_key: " BROWSERBASE_API_KEY " ,
50- browserbase_project_id: " BROWSERBASE_PROJECT_ID "
49+ browserbase_api_key: " <your API key here> " ,
50+ browserbase_project_id: " <your project ID here> "
5151 )
5252rescue Stagehand ::Errors ::APIConnectionError => e
5353 puts (" The server could not be reached" )
@@ -92,8 +92,8 @@ stagehand = Stagehand::Client.new(
9292
9393# Or, configure per-request:
9494stagehand.sessions.start(
95- browserbase_api_key: " BROWSERBASE_API_KEY " ,
96- browserbase_project_id: " BROWSERBASE_PROJECT_ID " ,
95+ browserbase_api_key: " <your API key here> " ,
96+ browserbase_project_id: " <your project ID here> " ,
9797 request_options: {max_retries: 5 }
9898)
9999```
@@ -110,8 +110,8 @@ stagehand = Stagehand::Client.new(
110110
111111# Or, configure per-request:
112112stagehand.sessions.start(
113- browserbase_api_key: " BROWSERBASE_API_KEY " ,
114- browserbase_project_id: " BROWSERBASE_PROJECT_ID " ,
113+ browserbase_api_key: " <your API key here> " ,
114+ browserbase_project_id: " <your project ID here> " ,
115115 request_options: {timeout: 5 }
116116)
117117```
@@ -145,8 +145,8 @@ Note: the `extra_` parameters of the same name overrides the documented paramete
145145``` ruby
146146response =
147147 stagehand.sessions.start(
148- browserbase_api_key: " BROWSERBASE_API_KEY " ,
149- browserbase_project_id: " BROWSERBASE_PROJECT_ID " ,
148+ browserbase_api_key: " <your API key here> " ,
149+ browserbase_project_id: " <your project ID here> " ,
150150 request_options: {
151151 extra_query: {my_query_parameter: value},
152152 extra_body: {my_body_parameter: value},
@@ -192,18 +192,18 @@ This library provides comprehensive [RBI](https://sorbet.org/docs/rbi) definitio
192192You can provide typesafe request parameters like so:
193193
194194``` ruby
195- stagehand.sessions.act(" 182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e " , input: " click the first link on the page" )
195+ stagehand.sessions.act(" 00000000-your-session-id-000000000000 " , input: " click the first link on the page" )
196196```
197197
198198Or, equivalently:
199199
200200``` ruby
201201# Hashes work, but are not typesafe:
202- stagehand.sessions.act(" 182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e " , input: " click the first link on the page" )
202+ stagehand.sessions.act(" 00000000-your-session-id-000000000000 " , input: " click the first link on the page" )
203203
204204# You can also splat a full Params class:
205205params = Stagehand ::SessionActParams .new (input: " click the first link on the page" )
206- stagehand.sessions.act(" 182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e " , ** params)
206+ stagehand.sessions.act(" 00000000-your-session-id-000000000000 " , ** params)
207207```
208208
209209### Enums
0 commit comments