This page provides a curated list of code samples that you can use to
accelerate your development with the ABAP SDK for Google Cloud.


For a comprehensive collection of code samples for the
SAP BTP edition of ABAP SDK for Google Cloud,
see the [code sample repository on GitHub](https://github.com/GoogleCloudPlatform/abapsdk-btp-samples/tree/main/src/zgoog_sdk_btp_code_samples).

For a comprehensive collection of code samples for the
on-premises or any cloud edition of ABAP SDK for Google Cloud,
see the [code samples repository on GitHub](https://github.com/GoogleCloudPlatform/google-cloud-abap/tree/main/abap-sdk/ZGOOG_SDK_DOCS_SAMPLES).

<br />

### SAP BTP edition

#### Pub/Sub

- [Publish topics](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/ps-publish-topics.md.txt#sap-btp-edition)
- [Pull subscriptions](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/ps-pull-subscriptions.md.txt#sap-btp-edition)
- [Create topic](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/ps-create-topic.md.txt#sap-btp-edition)
- [Create subscription](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/ps-create-subscription.md.txt#sap-btp-edition)
- [List subscriptions of a topic](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/ps-list-subscriptions-topic.md.txt#sap-btp-edition)

#### Cloud Storage

- [Create bucket](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/gcs-create-bucket.md.txt#sap-btp-edition)
- [List buckets](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/gcs-list-buckets.md.txt#sap-btp-edition)
- [Upload file to a bucket](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/gcs-upload-file-bucket.md.txt#sap-btp-edition)
- [Retrieve metadata of a file](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/gcs-retrieve-metadata-file.md.txt#sap-btp-edition)
- [Download file from a bucket](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/gcs-download-file-bucket.md.txt#sap-btp-edition)
- [Upload file with chunking and customer supplied encryption key](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/gcs-upload-file-chunking-customer-supplied-key.md.txt#sap-btp-edition)

#### Document AI

- [Process a single document](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-process-single-document.md.txt#sap-btp-edition)
- [Send a document for human review](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-send-document-for-human-review.md.txt#sap-btp-edition)
- [Batch process multiple documents](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-batch-process-multiple-documents.md.txt#sap-btp-edition)
- [Process a single document with a processor version](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-process-single-document-with-processor-version.md.txt#sap-btp-edition)
- [Batch process multiple documents with a processor version](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-batch-process-multiple-documents-with-processor-version.md.txt#sap-btp-edition)
- [Get the latest state of a long-running operation](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-get-latest-state-long-running-operation.md.txt#sap-btp-edition)
- [Start asynchronous cancellation on a long-running operation](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-start-asynchronous-cancellation-long-running-operation.md.txt#sap-btp-edition)

#### Secret Manager

- [Create secret](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/sm-create-secret.md.txt#sap-btp-edition)
- [Add secret version](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/sm-add-secret-version.md.txt#sap-btp-edition)
- [Access secret version](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/sm-access-secret-version.md.txt#sap-btp-edition)
- [Patch secret](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/sm-patch-secret.md.txt#sap-btp-edition)
- [Destroy secret version](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/sm-destroy-secret-version.md.txt#sap-btp-edition)
- [Delete secret](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/sm-delete-secret.md.txt#sap-btp-edition)

#### Cloud Translation

- [Create glossary](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/trans-create-glossary.md.txt#sap-btp-edition)
- [Translate with glossary](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/trans-translate-glossary.md.txt#sap-btp-edition)
- [Translate text in batch mode](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/trans-translate-text-batch-mode.md.txt#sap-btp-edition)
- [Translate document in batch mode](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/trans-translate-document-batch-mode.md.txt#sap-btp-edition)

### On-premises or any cloud edition

#### Pub/Sub

- [Publish topics](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/ps-publish-topics.md.txt#on-premises-or-any-cloud-edition)
- [Pull subscriptions](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/ps-pull-subscriptions.md.txt#on-premises-or-any-cloud-edition)
- [Create topic](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/ps-create-topic.md.txt#on-premises-or-any-cloud-edition)
- [Create subscription](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/ps-create-subscription.md.txt#on-premises-or-any-cloud-edition)
- [List subscriptions of a topic](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/ps-list-subscriptions-topic.md.txt#on-premises-or-any-cloud-edition)

#### Cloud Storage

- [Create bucket](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/gcs-create-bucket.md.txt#on-premises-or-any-cloud-edition)
- [List buckets](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/gcs-list-buckets.md.txt#on-premises-or-any-cloud-edition)
- [Upload file to a bucket](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/gcs-upload-file-bucket.md.txt#on-premises-or-any-cloud-edition)
- [Retrieve metadata of a file](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/gcs-retrieve-metadata-file.md.txt#on-premises-or-any-cloud-edition)
- [Download file from a bucket](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/gcs-download-file-bucket.md.txt#on-premises-or-any-cloud-edition)
- [Upload file with chunking and customer supplied encryption key](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/gcs-upload-file-chunking-customer-supplied-key.md.txt#on-premises-or-any-cloud-edition)

#### Document AI

- [Process a single document](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-process-single-document.md.txt#on-premises-or-any-cloud-edition)
- [Send a document for human review](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-send-document-for-human-review.md.txt#on-premises-or-any-cloud-edition)
- [Batch process multiple documents](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-batch-process-multiple-documents.md.txt#on-premises-or-any-cloud-edition)
- [Process a single document with a processor version](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-process-single-document-with-processor-version.md.txt#on-premises-or-any-cloud-edition)
- [Batch process multiple documents with a processor version](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-batch-process-multiple-documents-with-processor-version.md.txt#on-premises-or-any-cloud-edition)
- [Get the latest state of a long-running operation](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-get-latest-state-long-running-operation.md.txt#on-premises-or-any-cloud-edition)
- [Start asynchronous cancellation on a long-running operation](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/docai-start-asynchronous-cancellation-long-running-operation.md.txt#on-premises-or-any-cloud-edition)

#### Secret Manager

- [Create secret](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/sm-create-secret.md.txt#on-premises-or-any-cloud-edition)
- [Add secret version](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/sm-add-secret-version.md.txt#on-premises-or-any-cloud-edition)
- [Access secret version](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/sm-access-secret-version.md.txt#on-premises-or-any-cloud-edition)
- [Patch secret](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/sm-patch-secret.md.txt#on-premises-or-any-cloud-edition)
- [Destroy secret version](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/sm-destroy-secret-version.md.txt#on-premises-or-any-cloud-edition)
- [Delete secret](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/sm-delete-secret.md.txt#on-premises-or-any-cloud-edition)

#### Cloud Translation

- [Create glossary](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/trans-create-glossary.md.txt#on-premises-or-any-cloud-edition)
- [Translate with glossary](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/trans-translate-glossary.md.txt#on-premises-or-any-cloud-edition)
- [Translate text in batch mode](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/trans-translate-text-batch-mode.md.txt#on-premises-or-any-cloud-edition)
- [Translate document in batch mode](https://docs.cloud.google.com/sap/docs/abap-sdk/samples/trans-translate-document-batch-mode.md.txt#on-premises-or-any-cloud-edition)