Skip to content

Commit b7ae71d

Browse files
📚 update examples
1 parent 09059dc commit b7ae71d

File tree

6 files changed

+21
-6
lines changed

6 files changed

+21
-6
lines changed

examples/github_integration/with_application.py renamed to examples/deployments/create_integration/with_application.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,4 @@
66
async def example():
77
app = await client.app('application_id')
88
webhook_url = await app.github_integration(access_token='access_token')
9-
print(
10-
webhook_url
11-
) # https://api.squarecloud.app/v2/git/webhook/<webhook-code>
9+
print(webhook_url)

examples/github_integration/with_client.py renamed to examples/deployments/create_integration/with_client.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,4 @@ async def example():
77
webhook_url = await client.github_integration(
88
'application_id', access_token='access_token'
99
)
10-
print(
11-
webhook_url
12-
) # https://api.squarecloud.app/v2/git/webhook/<webhook-code>
10+
print(webhook_url)
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
import squarecloud as square
2+
3+
client = square.Client(api_key='API KEY')
4+
5+
6+
async def example():
7+
app = await client.app('application_id')
8+
webhook_url = await app.current_integration()
9+
print(webhook_url)
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import squarecloud as square
2+
3+
client = square.Client(api_key='API KEY')
4+
5+
6+
async def example():
7+
webhook_url = await client.current_app_integration(
8+
'application_id',
9+
)
10+
print(webhook_url)

0 commit comments

Comments
 (0)