Skip to content
This repository was archived by the owner on Sep 5, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 30 additions & 30 deletions google/cloud/billing_v1/services/cloud_billing/async_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,17 +219,17 @@ async def get_billing_account(

from google.cloud import billing_v1

def sample_get_billing_account():
async def sample_get_billing_account():
# Create a client
client = billing_v1.CloudBillingClient()
client = billing_v1.CloudBillingAsyncClient()

# Initialize request argument(s)
request = billing_v1.GetBillingAccountRequest(
name="name_value",
)

# Make the request
response = client.get_billing_account(request=request)
response = await client.get_billing_account(request=request)

# Handle the response
print(response)
Expand Down Expand Up @@ -327,9 +327,9 @@ async def list_billing_accounts(

from google.cloud import billing_v1

def sample_list_billing_accounts():
async def sample_list_billing_accounts():
# Create a client
client = billing_v1.CloudBillingClient()
client = billing_v1.CloudBillingAsyncClient()

# Initialize request argument(s)
request = billing_v1.ListBillingAccountsRequest(
Expand All @@ -339,7 +339,7 @@ def sample_list_billing_accounts():
page_result = client.list_billing_accounts(request=request)

# Handle the response
for response in page_result:
async for response in page_result:
print(response)

Args:
Expand Down Expand Up @@ -422,17 +422,17 @@ async def update_billing_account(

from google.cloud import billing_v1

def sample_update_billing_account():
async def sample_update_billing_account():
# Create a client
client = billing_v1.CloudBillingClient()
client = billing_v1.CloudBillingAsyncClient()

# Initialize request argument(s)
request = billing_v1.UpdateBillingAccountRequest(
name="name_value",
)

# Make the request
response = client.update_billing_account(request=request)
response = await client.update_billing_account(request=request)

# Handle the response
print(response)
Expand Down Expand Up @@ -547,16 +547,16 @@ async def create_billing_account(

from google.cloud import billing_v1

def sample_create_billing_account():
async def sample_create_billing_account():
# Create a client
client = billing_v1.CloudBillingClient()
client = billing_v1.CloudBillingAsyncClient()

# Initialize request argument(s)
request = billing_v1.CreateBillingAccountRequest(
)

# Make the request
response = client.create_billing_account(request=request)
response = await client.create_billing_account(request=request)

# Handle the response
print(response)
Expand Down Expand Up @@ -644,9 +644,9 @@ async def list_project_billing_info(

from google.cloud import billing_v1

def sample_list_project_billing_info():
async def sample_list_project_billing_info():
# Create a client
client = billing_v1.CloudBillingClient()
client = billing_v1.CloudBillingAsyncClient()

# Initialize request argument(s)
request = billing_v1.ListProjectBillingInfoRequest(
Expand All @@ -657,7 +657,7 @@ def sample_list_project_billing_info():
page_result = client.list_project_billing_info(request=request)

# Handle the response
for response in page_result:
async for response in page_result:
print(response)

Args:
Expand Down Expand Up @@ -764,17 +764,17 @@ async def get_project_billing_info(

from google.cloud import billing_v1

def sample_get_project_billing_info():
async def sample_get_project_billing_info():
# Create a client
client = billing_v1.CloudBillingClient()
client = billing_v1.CloudBillingAsyncClient()

# Initialize request argument(s)
request = billing_v1.GetProjectBillingInfoRequest(
name="name_value",
)

# Make the request
response = client.get_project_billing_info(request=request)
response = await client.get_project_billing_info(request=request)

# Handle the response
print(response)
Expand Down Expand Up @@ -909,17 +909,17 @@ async def update_project_billing_info(

from google.cloud import billing_v1

def sample_update_project_billing_info():
async def sample_update_project_billing_info():
# Create a client
client = billing_v1.CloudBillingClient()
client = billing_v1.CloudBillingAsyncClient()

# Initialize request argument(s)
request = billing_v1.UpdateProjectBillingInfoRequest(
name="name_value",
)

# Make the request
response = client.update_project_billing_info(request=request)
response = await client.update_project_billing_info(request=request)

# Handle the response
print(response)
Expand Down Expand Up @@ -1032,17 +1032,17 @@ async def get_iam_policy(
from google.cloud import billing_v1
from google.iam.v1 import iam_policy_pb2 # type: ignore

def sample_get_iam_policy():
async def sample_get_iam_policy():
# Create a client
client = billing_v1.CloudBillingClient()
client = billing_v1.CloudBillingAsyncClient()

# Initialize request argument(s)
request = iam_policy_pb2.GetIamPolicyRequest(
resource="resource_value",
)

# Make the request
response = client.get_iam_policy(request=request)
response = await client.get_iam_policy(request=request)

# Handle the response
print(response)
Expand Down Expand Up @@ -1205,17 +1205,17 @@ async def set_iam_policy(
from google.cloud import billing_v1
from google.iam.v1 import iam_policy_pb2 # type: ignore

def sample_set_iam_policy():
async def sample_set_iam_policy():
# Create a client
client = billing_v1.CloudBillingClient()
client = billing_v1.CloudBillingAsyncClient()

# Initialize request argument(s)
request = iam_policy_pb2.SetIamPolicyRequest(
resource="resource_value",
)

# Make the request
response = client.set_iam_policy(request=request)
response = await client.set_iam_policy(request=request)

# Handle the response
print(response)
Expand Down Expand Up @@ -1379,9 +1379,9 @@ async def test_iam_permissions(
from google.cloud import billing_v1
from google.iam.v1 import iam_policy_pb2 # type: ignore

def sample_test_iam_permissions():
async def sample_test_iam_permissions():
# Create a client
client = billing_v1.CloudBillingClient()
client = billing_v1.CloudBillingAsyncClient()

# Initialize request argument(s)
request = iam_policy_pb2.TestIamPermissionsRequest(
Expand All @@ -1390,7 +1390,7 @@ def sample_test_iam_permissions():
)

# Make the request
response = client.test_iam_permissions(request=request)
response = await client.test_iam_permissions(request=request)

# Handle the response
print(response)
Expand Down
12 changes: 6 additions & 6 deletions google/cloud/billing_v1/services/cloud_catalog/async_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -218,9 +218,9 @@ async def list_services(

from google.cloud import billing_v1

def sample_list_services():
async def sample_list_services():
# Create a client
client = billing_v1.CloudCatalogClient()
client = billing_v1.CloudCatalogAsyncClient()

# Initialize request argument(s)
request = billing_v1.ListServicesRequest(
Expand All @@ -230,7 +230,7 @@ def sample_list_services():
page_result = client.list_services(request=request)

# Handle the response
for response in page_result:
async for response in page_result:
print(response)

Args:
Expand Down Expand Up @@ -297,9 +297,9 @@ async def list_skus(

from google.cloud import billing_v1

def sample_list_skus():
async def sample_list_skus():
# Create a client
client = billing_v1.CloudCatalogClient()
client = billing_v1.CloudCatalogAsyncClient()

# Initialize request argument(s)
request = billing_v1.ListSkusRequest(
Expand All @@ -310,7 +310,7 @@ def sample_list_skus():
page_result = client.list_skus(request=request)

# Handle the response
for response in page_result:
async for response in page_result:
print(response)

Args:
Expand Down
Loading