diff --git a/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/LICENSE b/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/LICENSE new file mode 100644 index 0000000000..8dc7c0703e --- /dev/null +++ b/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/LICENSE @@ -0,0 +1,35 @@ +Copyright (c) 2025 Oracle and/or its affiliates. + +The Universal Permissive License (UPL), Version 1.0 + +Subject to the condition set forth below, permission is hereby granted to any +person obtaining a copy of this software, associated documentation and/or data +(collectively the "Software"), free of charge and under any and all copyright +rights in the Software, and any and all patent rights owned or freely +licensable by each licensor hereunder covering either (i) the unmodified +Software as contributed to or provided by such licensor, or (ii) the Larger +Works (as defined below), to deal in both + +(a) the Software, and +(b) any piece of software and/or hardware listed in the lrgrwrks.txt file if +one is included with the Software (each a "Larger Work" to which the Software +is contributed by such licensors), + +without restriction, including without limitation the rights to copy, create +derivative works of, display, perform, and distribute the Software and make, +use, sell, offer for sale, import, export, have made, and have sold the +Software and the Larger Work(s), and to sublicense the foregoing rights on +either these or other terms. + +This license is subject to the following condition: +The above copyright notice and either this complete permission notice or at +a minimum a reference to the UPL must be included in all copies or +substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/README.md b/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/README.md new file mode 100644 index 0000000000..dd429bec74 --- /dev/null +++ b/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/README.md @@ -0,0 +1,21 @@ +# OIC Project & Deployment Export Import Guide + +This asset contains an OIC Gen3 implementation guide for exporting and importing OIC projects and deployments through Oracle Integration Developer APIs. It includes OAuth authentication requirements, uppercase payload examples, cURL commands, multipart archive upload guidance, and deployment conflict handling. A Postman Collection is also provided with sample requests for Get Project Deployments, Export Project, Export Deployment, and Import Project or Deployment. + +# When to use this asset? + +Use this asset as a reference or template when automating OIC project and deployment migration between environments. It is useful for backup, promotion, deployment recovery, and repeatable delivery processes. + +# How to use this asset? + +Review the [OIC Project and Deployment Export and Import Guide]( oci-and-db\cloud-native\app-integration-and-automation\oracle-integration-cloud\13-oic-project-and-deployment-export-import-guide\files\import-export-guide\README.md) , configure OAuth authentication, and replace the environment placeholders with your Oracle Integration values. + +For Postman collection, you can import the provided [Postman Collection](oci-and-db\cloud-native\app-integration-and-automation\oracle-integration-cloud\13-oic-project-and-deployment-export-import-guide\files\postman-collection\README.md) to run the included API samples for retrieving deployments, exporting projects or deployments, and importing archive files, ensure to replace the placeholders with your environment details. + +# License + +Copyright (c) 2026 Oracle and/or its affiliates. + +Licensed under the Universal Permissive License (UPL), Version 1.0. + +See [LICENSE](https://github.com/oracle-devrel/technology-engineering/blob/main/LICENSE.txt) for more details. diff --git a/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/files/import-export-guide/README.md b/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/files/import-export-guide/README.md new file mode 100644 index 0000000000..85e745479d --- /dev/null +++ b/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/files/import-export-guide/README.md @@ -0,0 +1,120 @@ +# OIC Project and Deployment Export and Import Guide + +Use the Oracle Integration 3 Developer API to export an entire project or one deployment, then import its archive into another environment. Export returns a downloadable `.CAR` archive. Import adds a project or deployment that is not already present in the target environment. + +## Prerequisite OAuth Authentication + +OAuth is required for Oracle Integration Developer APIs. Basic Authentication is not accepted by these APIs. Configure an OAuth client, obtain a valid access token, and send it with every request: + +```http +Authorization: Bearer +``` + +1. Configure an OAuth client and choose the appropriate grant type. +2. Request an access token. +3. Call the Developer API using the design-time URL and Bearer token. +4. Refresh the token when it expires. + +Further details: + +- [Oracle documentation - Security Authentication and Authorization](https://docs.oracle.com/en/cloud/paas/application-integration/rest-api/Authentication.html) +- [Step by step OAuth setup tutorial video](https://youtu.be/UrptzZbycm4?si=xz27moIXhua531m_) + +## Prepare the request + +Replace the following values for your environment: + +| Placeholder | Meaning | +|---|---| +| `` | Oracle Integration design host | +| `` | Valid OAuth access token | +| `` | Oracle Integration service instance name | +| `` | Project identifier, for example `TEST_PROJECT` | +| `` | Local `.CAR` archive, for example `TEST_PROJECT.CAR` | + +Use uppercase project values consistently. The examples use `TEST PROJECT`, `TEST_PROJECT`, and `DEVELOPED`. The `LABEL` value identifies a deployment. + +## Export an entire project + +**Endpoint** + +```text +POST https:///ic/api/integration/v1/projects//archive?integrationInstance= +``` + +**Project export payload** + +```json +{"name":"TEST PROJECT","code":"TEST_PROJECT","type":"DEVELOPED","builtBy":"","label":""} +``` + +Keep `label` empty for a full project export. + +```bash +curl -X POST \ + -H "Authorization: Bearer " \ + -H "Content-Type: application/json" \ + -d '{"name":"TEST PROJECT","code":"TEST_PROJECT","type":"DEVELOPED","builtBy":"","label":""}' \ + -o "TEST_PROJECT.CAR" \ + "https:///ic/api/integration/v1/projects/TEST_PROJECT/archive?integrationInstance=" +``` + +The successful response is an `application/octet-stream` archive. + +## Export a single deployment + +Use the same endpoint and supply the deployment identifier in `label`. + +```json +{"name":"TEST PROJECT","code":"TEST_PROJECT","type":"DEVELOPED","builtBy":"","label":"01.00.0000"} +``` + +```bash +curl -X POST \ + -H "Authorization: Bearer " \ + -H "Content-Type: application/json" \ + -d '{"name":"TEST PROJECT","code":"TEST_PROJECT","type":"DEVELOPED","builtBy":"","label":"01.00.0000"}' \ + -o "TEST_PROJECT_01.00.0000.CAR" \ + "https:///ic/api/integration/v1/projects/TEST_PROJECT/archive?integrationInstance=" +``` + +## Import an exported archive + +**Endpoint** + +```text +POST https:///ic/api/integration/v1/projects/archive?integrationInstance= +``` + +Upload the previously exported `.CAR` archive as `multipart/form-data` using the binary field named `file`. + +```bash +curl -X POST \ + -H "Authorization: Bearer " \ + -F "file=@TEST_PROJECT.CAR" \ + -F "type=application/octet-stream" \ + "https:///ic/api/integration/v1/projects/archive?integrationInstance=" +``` + +The project or deployment being imported must not already exist in the target environment. A conflict returns HTTP `409` when the project already exists. + +| Status | Meaning | +|---|---| +| `200` | Successful import | +| `400` | No file uploaded | +| `409` | Project already exists | +| `500` | Server error | + +## Source documentation + +- [Export a Project](https://docs.oracle.com/en/cloud/paas/application-integration/rest-api/op-ic-api-integration-v1-projects-id-archive-post.html) +- [Import Add a Project](https://docs.oracle.com/en/cloud/paas/application-integration/rest-api/op-ic-api-integration-v1-projects-archive-post.html) + + +# License + +Copyright (c) 2026 Oracle and/or its affiliates. + +Licensed under the Universal Permissive License (UPL), Version 1.0. + +See [LICENSE](https://github.com/oracle-devrel/technology-engineering/blob/main/LICENSE.txt) for more details. \ No newline at end of file diff --git a/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/files/postman-collection/OIC Project Export Import.postman_collection.json b/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/files/postman-collection/OIC Project Export Import.postman_collection.json new file mode 100644 index 0000000000..4fb780d763 --- /dev/null +++ b/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/files/postman-collection/OIC Project Export Import.postman_collection.json @@ -0,0 +1,334 @@ +{ + "info": { + "_postman_id": "1301db2b-b2cb-4c8e-becb-87a10f64b697", + "name": "OIC Project Export Import", + "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json", + "_exporter_id": "1644679" + }, + "item": [ + { + "name": "Get Project Deployments", + "request": { + "auth": { + "type": "oauth2", + "oauth2": [ + { + "key": "addTokenTo", + "value": "header", + "type": "string" + }, + { + "key": "grant_type", + "value": "client_credentials", + "type": "string" + }, + { + "key": "accessTokenUrl", + "value": "{{access_token_url}}", + "type": "string" + }, + { + "key": "clientId", + "value": "{{client_id}}", + "type": "string" + }, + { + "key": "clientSecret", + "value": "{{client_secret}}", + "type": "string" + }, + { + "key": "scope", + "value": "{{scope}}", + "type": "string" + }, + { + "key": "tokenName", + "value": "teamoic3_token", + "type": "string" + } + ] + }, + "method": "GET", + "header": [], + "url": { + "raw": "https://design.integration.eu-frankfurt-1.ocp.oraclecloud.com/ic/api/integration/v1/projects/{{project_id}}/deployments?integrationInstance={{integration_instance}}", + "protocol": "https", + "host": [ + "design", + "integration", + "eu-frankfurt-1", + "ocp", + "oraclecloud", + "com" + ], + "path": [ + "ic", + "api", + "integration", + "v1", + "projects", + "{{project_id}}", + "deployments" + ], + "query": [ + { + "key": "integrationInstance", + "value": "{{integration_instance}}" + } + ] + } + }, + "response": [] + }, + { + "name": "Export Project", + "request": { + "auth": { + "type": "oauth2", + "oauth2": [ + { + "key": "clientId", + "value": "{{client_id}}", + "type": "string" + }, + { + "key": "accessTokenUrl", + "value": "{{access_token_url}}", + "type": "string" + }, + { + "key": "tokenName", + "value": "", + "type": "string" + }, + { + "key": "addTokenTo", + "value": "header", + "type": "string" + }, + { + "key": "clientSecret", + "value": "{{client_secret}}", + "type": "string" + }, + { + "key": "scope", + "value": "{{scope}}", + "type": "string" + }, + { + "key": "grant_type", + "value": "client_credentials", + "type": "string" + } + ] + }, + "method": "POST", + "header": [], + "body": { + "mode": "raw", + "raw": "{\r\n \"name\": \"HQ ERP PROJECT\",\r\n \"code\": \"HQ_ERP_PROJECT\",\r\n \"type\": \"DEVELOPED\",\r\n \"builtBy\": \"\",\r\n \"label\": \"\"\r\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": { + "raw": "https://design.integration.eu-frankfurt-1.ocp.oraclecloud.com/ic/api/integration/v1/projects/{{project_id}}/archive?integrationInstance={{integration_instance}}", + "protocol": "https", + "host": [ + "design", + "integration", + "eu-frankfurt-1", + "ocp", + "oraclecloud", + "com" + ], + "path": [ + "ic", + "api", + "integration", + "v1", + "projects", + "{{project_id}}", + "archive" + ], + "query": [ + { + "key": "integrationInstance", + "value": "{{integration_instance}}" + } + ] + } + }, + "response": [] + }, + { + "name": "Export Deployment", + "request": { + "auth": { + "type": "oauth2", + "oauth2": [ + { + "key": "clientId", + "value": "{{client_id}}", + "type": "string" + }, + { + "key": "accessTokenUrl", + "value": "{{access_token_url}}", + "type": "string" + }, + { + "key": "tokenName", + "value": "", + "type": "string" + }, + { + "key": "addTokenTo", + "value": "header", + "type": "string" + }, + { + "key": "clientSecret", + "value": "{{client_secret}}", + "type": "string" + }, + { + "key": "scope", + "value": "{{scope}}", + "type": "string" + }, + { + "key": "grant_type", + "value": "client_credentials", + "type": "string" + } + ] + }, + "method": "POST", + "header": [], + "body": { + "mode": "raw", + "raw": "{\r\n \"name\": \"HQ ERP PROJECT\",\r\n \"code\": \"HQ_ERP_PROJECT\",\r\n \"type\": \"DEVELOPED\",\r\n \"builtBy\": \"\",\r\n \"label\": \"DEPLOYMENT1\"\r\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": { + "raw": "https://design.integration.eu-frankfurt-1.ocp.oraclecloud.com/ic/api/integration/v1/projects/{{project_id}}/archive?integrationInstance={{integration_instance}}", + "protocol": "https", + "host": [ + "design", + "integration", + "eu-frankfurt-1", + "ocp", + "oraclecloud", + "com" + ], + "path": [ + "ic", + "api", + "integration", + "v1", + "projects", + "{{project_id}}", + "archive" + ], + "query": [ + { + "key": "integrationInstance", + "value": "{{integration_instance}}" + } + ] + } + }, + "response": [] + }, + { + "name": "Import Project or Deployment", + "request": { + "auth": { + "type": "oauth2", + "oauth2": [ + { + "key": "addTokenTo", + "value": "header", + "type": "string" + }, + { + "key": "grant_type", + "value": "client_credentials", + "type": "string" + }, + { + "key": "accessTokenUrl", + "value": "{{access_token_url}}", + "type": "string" + }, + { + "key": "clientId", + "value": "{{client_id}}", + "type": "string" + }, + { + "key": "clientSecret", + "value": "{{client_secret}}", + "type": "string" + }, + { + "key": "scope", + "value": "{{scope}}", + "type": "string" + } + ] + }, + "method": "POST", + "header": [], + "body": { + "mode": "formdata", + "formdata": [ + { + "key": "file", + "type": "file", + "src": [ + "/C:/Users/Harris/Downloads/HQ_ERP_PROJECT-DEPLOYMENT1.car" + ] + } + ] + }, + "url": { + "raw": "https://design.integration.eu-frankfurt-1.ocp.oraclecloud.com/ic/api/integration/v1/projects/archive?integrationInstance={{integration_instance}}", + "protocol": "https", + "host": [ + "design", + "integration", + "eu-frankfurt-1", + "ocp", + "oraclecloud", + "com" + ], + "path": [ + "ic", + "api", + "integration", + "v1", + "projects", + "archive" + ], + "query": [ + { + "key": "integrationInstance", + "value": "{{integration_instance}}" + } + ] + } + }, + "response": [] + } + ] +} \ No newline at end of file diff --git a/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/files/postman-collection/README.md b/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/files/postman-collection/README.md new file mode 100644 index 0000000000..c20390196e --- /dev/null +++ b/oci-and-db/cloud-native/app-integration-and-automation/oracle-integration-cloud/13-oic-project-and-deployment-export-import-guide/files/postman-collection/README.md @@ -0,0 +1,58 @@ +# OIC Project Export Import Postman Collection + +This collection helps you retrieve OIC project deployments and export or import OIC project archives. It uses OAuth 2.0 Client Credentials authentication; Basic Authentication is not supported for Oracle Integration Developer APIs. + +## Setup + +Import `OIC Project Export Import.postman_collection.json` into Postman. Create or select an environment and provide these variables: + +| Variable | Description | +|---|---| +| `access_token_url` | OAuth token endpoint | +| `client_id` | OAuth client ID | +| `client_secret` | OAuth client secret | +| `scope` | OAuth scope required by the client | +| `integration_instance` | Oracle Integration service instance name | +| `project_id` | OIC project identifier, for example `HQ_ERP_PROJECT` | + +Use uppercase project names and codes in the export request bodies. Update the import request to point to the local `.CAR` archive you want to upload. + +## APIs + +### Get Project Deployments + +`GET /ic/api/integration/v1/projects/{{project_id}}/deployments` + +Lists deployments for the selected project. Use the returned deployment identifier as the `label` when exporting one deployment. + +### Export Project + +`POST /ic/api/integration/v1/projects/{{project_id}}/archive` + +Exports the complete project as a `.CAR` archive. Keep `label` empty in the request body. + +### Export Deployment + +`POST /ic/api/integration/v1/projects/{{project_id}}/archive` + +Exports one deployment as a `.CAR` archive. Set `label` to the deployment identifier, for example `DEPLOYMENT1`. + +### Import Project or Deployment + +`POST /ic/api/integration/v1/projects/archive` + +Imports a previously exported `.CAR` archive. The request uses `multipart/form-data` with the binary field named `file`. The destination project or deployment must not already exist; otherwise, the import fails with a conflict error. + +## References + +- [Authentication](https://docs.oracle.com/en/cloud/paas/application-integration/rest-api/Authentication.html) +- [Export a Project](https://docs.oracle.com/en/cloud/paas/application-integration/rest-api/op-ic-api-integration-v1-projects-id-archive-post.html) +- [Import Add a Project](https://docs.oracle.com/en/cloud/paas/application-integration/rest-api/op-ic-api-integration-v1-projects-archive-post.html) + +# License + +Copyright (c) 2026 Oracle and/or its affiliates. + +Licensed under the Universal Permissive License (UPL), Version 1.0. + +See [LICENSE](https://github.com/oracle-devrel/technology-engineering/blob/main/LICENSE.txt) for more details.