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

# Update Portfolio Folders for the current user

> Creates or removes folders for the current user.

<Note>
  Use the [**<u>Login</u>**<u> endpoint</u>](/api-reference/user/logs-a-user-in) to retrieve the **`SessionKey`**, then include it in the **Authorization** field for authentication.
</Note>


## OpenAPI

````yaml post /v1/Portfolio/Folders
openapi: 3.0.0
info:
  version: v2
  title: Credit Risk Monitor API
servers:
  - url: https://api.creditriskmonitor.com
security: []
paths:
  /v1/Portfolio/Folders:
    post:
      tags:
        - Portfolio
      summary: Creates or Deletes a Portfolio Folder for the current user
      operationId: Portfolio_CreateDeleteFolder
      parameters:
        - name: Folder
          in: query
          description: Name of the folder to create
          required: false
          schema:
            type: string
        - name: DeleteFolderId
          in: query
          description: FolderId of the folder to Delete
          required: false
          schema:
            type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIResponseContainer_APIPortfolioFolder_'
            text/json:
              schema:
                $ref: '#/components/schemas/APIResponseContainer_APIPortfolioFolder_'
            text/html:
              schema:
                $ref: '#/components/schemas/APIResponseContainer_APIPortfolioFolder_'
            application/xml:
              schema:
                $ref: '#/components/schemas/APIResponseContainer_APIPortfolioFolder_'
            text/xml:
              schema:
                $ref: '#/components/schemas/APIResponseContainer_APIPortfolioFolder_'
components:
  schemas:
    APIResponseContainer_APIPortfolioFolder_:
      description: ''
      type: object
      properties:
        Success:
          description: ''
          type: boolean
        Data:
          $ref: '#/components/schemas/APIPortfolioFolder'
        ErrorCode:
          description: ''
          type: string
    APIPortfolioFolder:
      description: ApiPortfolioFolder
      type: object
      properties:
        FolderId:
          format: int32
          description: Id of the Folder
          type: integer
        UserId:
          format: int32
          description: UserId of the User that owns this Folder
          type: integer
        FolderName:
          description: Name of the Folder
          type: string
        DateCreated:
          format: date-time
          description: Creation Date
          type: string
        DateUpdated:
          format: date-time
          description: Updated Date
          type: string

````