> ## Documentation Index
> Fetch the complete documentation index at: https://docs.opal.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Post bundles resources

> Adds a resource to a bundle.



## OpenAPI

````yaml https://app.opal.dev/openapi.yaml post /bundles/{bundle_id}/resources
openapi: 3.1.0
info:
  contact:
    email: hello@opal.dev
    name: Opal Team
    url: https://www.opal.dev/
  description: >-
    The Opal API is a RESTful API that allows you to interact with the Opal
    Security platform programmatically.
  title: Opal API
  version: '1.0'
servers:
  - description: Production
    url: https://api.opal.dev/v1
security: []
tags:
  - name: access-rules
    description: Operations related to access rules
  - name: apps
    description: Operations related to apps
  - name: bundles
    description: Operations related to bundles
  - name: configuration-templates
    description: Operations related to configuration templates
  - name: delegations
    description: Operations related to request reviewer delegations
  - name: events
    description: Operations related to events
  - name: groups
    description: Operations related to groups
  - name: group-bindings
    description: Operations related to group bindings
  - name: idp-group-mappings
    description: Operations related to IDP group mappings
  - name: message-channels
    description: Operations related to message channels
  - name: non-human-identities
    description: Operations related to non-human identities
  - name: on-call-schedules
    description: Operations related to on-call schedules
  - name: owners
    description: Operations related to owners
  - name: requests
    description: Operations related to requests
  - name: resources
    description: Operations related to resources
  - name: sessions
    description: Operations related to sessions
  - name: tags
    description: Operations related to tags
  - name: tokens
    description: Operations related to API tokens
  - name: uars
    description: Operations related to UARs
  - name: users
    description: Operations related to users
paths:
  /bundles/{bundle_id}/resources:
    post:
      tags:
        - bundles
      description: Adds a resource to a bundle.
      operationId: addBundleResource
      parameters:
        - description: The ID of the bundle.
          example: 32acc112-21ff-4669-91c2-21e27683eaa1
          in: path
          name: bundle_id
          required: true
          schema:
            type: string
            format: uuid
      requestBody:
        required: false
        content:
          application/json:
            schema:
              properties:
                resource_id:
                  description: The ID of the resource to add.
                  example: 72e75a6f-7183-48c5-94ff-6013f213314b
                  format: uuid
                  type: string
                access_level_remote_id:
                  description: >-
                    The remote ID of the access level to grant to this user.
                    Required if the resource being added requires an access
                    level. If omitted, the default access level remote ID value
                    (empty string) is used.
                  example: arn:aws:iam::590304332660:role/AdministratorAccess
                  type: string
                access_level_name:
                  description: >-
                    The name of the access level to grant to this user. If
                    omitted, the default access level name value (empty string)
                    is used.
                  example: AdministratorAccess
                  type: string
              required:
                - resource_id
      responses:
        '201':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BundleResource'
          description: Resource was successfully added to the bundle.
      security:
        - BearerAuth: []
components:
  schemas:
    BundleResource:
      properties:
        bundle_id:
          description: The ID of the bundle containing the resource.
          example: a381e7a3-e5e0-4c48-b1d6-4ccb4c191bc1
          format: uuid
          type: string
          readOnly: true
        resource_id:
          description: The ID of the resource within a bundle.
          example: a381e7a3-e5e0-4c48-b1d6-4ccb4c191bc1
          format: uuid
          type: string
          readOnly: true
        access_level_name:
          description: The access level of the resource within a bundle.
          example: Read
          type: string
        access_level_remote_id:
          description: The remote ID of the access level of the resource within a bundle.
          example: arn:aws:iam::490306337630:role/SupportUser
          type: string
  securitySchemes:
    BearerAuth:
      scheme: bearer
      type: http

````