From 0184693a27b4c41b03bdecfd91f2ec3e3c75b0ae Mon Sep 17 00:00:00 2001 From: alitariksahin Date: Thu, 28 Aug 2025 21:15:13 +0300 Subject: [PATCH 1/3] create openapi.yml for developer api --- devops/developer-api/openapi.yml | 1843 +++++++++++++++++ devops/developer-api/redis/autoscaling.mdx | 0 .../redis/backup/create_backup.mdx | 64 - .../redis/backup/delete_backup.mdx | 56 - .../redis/backup/disable_dailybackup.mdx | 52 - .../redis/backup/enable_dailybackup.mdx | 52 - .../redis/backup/list_backup.mdx | 105 - .../redis/backup/restore_backup.mdx | 64 - devops/developer-api/redis/change_plan.mdx | 75 - .../developer-api/redis/create_database.mdx | 121 -- .../redis/create_database_global.mdx | 142 -- .../developer-api/redis/delete_database.mdx | 53 - .../redis/disable_autoscaling.mdx | 49 - .../developer-api/redis/disable_eviction.mdx | 55 - .../redis/enable_autoscaling.mdx | 55 - .../developer-api/redis/enable_eviction.mdx | 55 - devops/developer-api/redis/enable_tls.mdx | 103 - devops/developer-api/redis/get_database.mdx | 146 -- .../redis/get_database_stats.mdx | 440 ---- devops/developer-api/redis/list_databases.mdx | 106 - devops/developer-api/redis/moveto_team.mdx | 60 - .../developer-api/redis/rename_database.mdx | 258 --- devops/developer-api/redis/reset_password.mdx | 107 - devops/developer-api/redis/update_budget.mdx | 64 - devops/developer-api/redis/update_regions.mdx | 67 - .../developer-api/teams/add_team_member.mdx | 90 - devops/developer-api/teams/create_team.mdx | 81 - devops/developer-api/teams/delete_team.mdx | 57 - .../teams/delete_team_member.mdx | 68 - .../developer-api/teams/get_team_members.mdx | 81 - devops/developer-api/teams/list_teams.mdx | 69 - devops/developer-api/vector/create_index.mdx | 212 -- devops/developer-api/vector/delete_index.mdx | 80 - devops/developer-api/vector/get_index.mdx | 166 -- devops/developer-api/vector/list_indices.mdx | 162 -- devops/developer-api/vector/rename_index.mdx | 96 - .../vector/reset_index_passwords.mdx | 85 - .../developer-api/vector/set_index_plan.mdx | 97 - .../developer-api/vector/transfer_index.mdx | 98 - docs.json | 74 +- 40 files changed, 1880 insertions(+), 3828 deletions(-) create mode 100644 devops/developer-api/openapi.yml delete mode 100644 devops/developer-api/redis/autoscaling.mdx delete mode 100644 devops/developer-api/redis/backup/create_backup.mdx delete mode 100644 devops/developer-api/redis/backup/delete_backup.mdx delete mode 100644 devops/developer-api/redis/backup/disable_dailybackup.mdx delete mode 100644 devops/developer-api/redis/backup/enable_dailybackup.mdx delete mode 100644 devops/developer-api/redis/backup/list_backup.mdx delete mode 100644 devops/developer-api/redis/backup/restore_backup.mdx delete mode 100644 devops/developer-api/redis/change_plan.mdx delete mode 100644 devops/developer-api/redis/create_database.mdx delete mode 100644 devops/developer-api/redis/create_database_global.mdx delete mode 100644 devops/developer-api/redis/delete_database.mdx delete mode 100644 devops/developer-api/redis/disable_autoscaling.mdx delete mode 100644 devops/developer-api/redis/disable_eviction.mdx delete mode 100644 devops/developer-api/redis/enable_autoscaling.mdx delete mode 100644 devops/developer-api/redis/enable_eviction.mdx delete mode 100644 devops/developer-api/redis/enable_tls.mdx delete mode 100644 devops/developer-api/redis/get_database.mdx delete mode 100644 devops/developer-api/redis/get_database_stats.mdx delete mode 100644 devops/developer-api/redis/list_databases.mdx delete mode 100644 devops/developer-api/redis/moveto_team.mdx delete mode 100644 devops/developer-api/redis/rename_database.mdx delete mode 100644 devops/developer-api/redis/reset_password.mdx delete mode 100644 devops/developer-api/redis/update_budget.mdx delete mode 100644 devops/developer-api/redis/update_regions.mdx delete mode 100644 devops/developer-api/teams/add_team_member.mdx delete mode 100644 devops/developer-api/teams/create_team.mdx delete mode 100644 devops/developer-api/teams/delete_team.mdx delete mode 100644 devops/developer-api/teams/delete_team_member.mdx delete mode 100644 devops/developer-api/teams/get_team_members.mdx delete mode 100644 devops/developer-api/teams/list_teams.mdx delete mode 100644 devops/developer-api/vector/create_index.mdx delete mode 100644 devops/developer-api/vector/delete_index.mdx delete mode 100644 devops/developer-api/vector/get_index.mdx delete mode 100644 devops/developer-api/vector/list_indices.mdx delete mode 100644 devops/developer-api/vector/rename_index.mdx delete mode 100644 devops/developer-api/vector/reset_index_passwords.mdx delete mode 100644 devops/developer-api/vector/set_index_plan.mdx delete mode 100644 devops/developer-api/vector/transfer_index.mdx diff --git a/devops/developer-api/openapi.yml b/devops/developer-api/openapi.yml new file mode 100644 index 00000000..2fccdfbd --- /dev/null +++ b/devops/developer-api/openapi.yml @@ -0,0 +1,1843 @@ +openapi: 3.0.4 +info: + title: Developer API - Upstash + description: |- + This is a documentation to specify Developer API endpoints based on the OpenAPI 3.0 specification. + contact: + name: Support Team + email: support@upstash.com + license: + name: Apache 2.0 + url: https://www.apache.org/licenses/LICENSE-2.0.html + version: 1.0.0 +externalDocs: + description: Find out more about Upstash + url: https://upstash.com/ +servers: + - url: https://api.upstash.com/v2 +tags: + - name: redis + description: Manage redis databases. + externalDocs: + description: Find out more + url: https://upstash.com/docs/devops/developer-api/introduction + - name: teams + description: Manage teams and team members. + externalDocs: + description: Find out more + url: https://upstash.com/docs/devops/developer-api/introduction + - name: vector + description: Manage vector indices. + externalDocs: + description: Find out more + url: https://upstash.com/docs/devops/developer-api/introduction + +paths: + /redis/databases: + get: + tags: + - redis + summary: List Databases + x-mint: + href: /devops/developer-api/redis/list_databases + description: This endpoint list all databases of user. + operationId: listDatabases + responses: + "200": + description: OK + content: + application/json: + schema: + type: array + items: + $ref: "#/components/schemas/Database" + security: + - basicAuth: [] + /redis/database/{id}: + get: + tags: + - redis + summary: Get Database + x-mint: + href: /devops/developer-api/redis/get_database + description: This endpoint gets details of a database. + operationId: getDatabase + parameters: + - name: id + in: path + description: The ID of the database to reset password + required: true + schema: + type: string + - name: credentials + in: query + description: Set to 'hide' to remove credentials from the response. + schema: + type: string + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/Database" + security: + - basicAuth: [] + delete: + tags: + - redis + summary: Delete Database + x-mint: + href: /devops/developer-api/redis/delete_database + description: This endpoint deletes a database. + operationId: deleteDatabase + parameters: + - name: id + in: path + description: The ID of the database to be deleted + required: true + schema: + type: string + responses: + "200": + description: OK + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /redis/database: + post: + tags: + - redis + summary: Create Redis Database + description: This endpoint creates a new Redis database. + x-mint: + href: /devops/developer-api/redis/create_database_global + operationId: createDatabase + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/CreateDatabaseRequest" + responses: + "200": + description: Database created successfully + content: + application/json: + schema: + $ref: "#/components/schemas/Database" + security: + - basicAuth: [] + /redis/rename/{id}: + post: + tags: + - redis + summary: Rename Database + description: This endpoint renames a database. + x-mint: + href: /devops/developer-api/redis/rename_database + operationId: renameDatabase + parameters: + - name: id + in: path + description: The ID of the database to be renamed + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + name: + type: string + description: The new name of the database + required: + - name + responses: + "200": + description: Database renamed successfully + content: + application/json: + schema: + $ref: "#/components/schemas/Database" + security: + - basicAuth: [] + /redis/reset-password/{id}: + post: + tags: + - redis + summary: Reset Password + description: This endpoint updates the password of a database. + x-mint: + href: /devops/developer-api/redis/reset_password + operationId: resetPassword + parameters: + - name: id + in: path + description: The ID of the database to reset password + required: true + schema: + type: string + responses: + "200": + description: Password reset successfully + content: + application/json: + schema: + $ref: "#/components/schemas/Database" + security: + - basicAuth: [] + /redis/enable-tls/{id}: + post: + tags: + - redis + summary: Enable TLS + description: This endpoint enables tls on a database. + x-mint: + href: /devops/developer-api/redis/enable_tls + operationId: enableTls + parameters: + - name: id + in: path + description: The ID of the database to enable TLS + required: true + schema: + type: string + responses: + "200": + description: TLS enabled successfully + content: + application/json: + schema: + $ref: "#/components/schemas/Database" + security: + - basicAuth: [] + /redis/enable-eviction/{id}: + post: + tags: + - redis + summary: Enable Eviction + description: This endpoint enables eviction for given database. + x-mint: + href: /devops/developer-api/redis/enable_eviction + operationId: enableEviction + parameters: + - name: id + in: path + description: The ID of the database to enable eviction + required: true + schema: + type: string + responses: + "200": + description: Eviction enabled successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /redis/disable-eviction/{id}: + post: + tags: + - redis + summary: Disable Eviction + description: This endpoint disables eviction for given database. + x-mint: + href: /devops/developer-api/redis/disable_eviction + operationId: disableEviction + parameters: + - name: id + in: path + description: The ID of the database to disable eviction + required: true + schema: + type: string + responses: + "200": + description: Eviction disabled successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /redis/enable-autoupgrade/{id}: + post: + tags: + - redis + summary: Enable Auto Upgrade + description: This endpoint enables Auto Upgrade for given database. + x-mint: + href: /devops/developer-api/redis/enable_autoscaling + operationId: enableAutoUpgrade + parameters: + - name: id + in: path + description: The ID of the database to enable auto upgrade + required: true + schema: + type: string + responses: + "200": + description: Auto upgrade enabled successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /redis/disable-autoupgrade/{id}: + post: + tags: + - redis + summary: Disable Auto Upgrade + description: This endpoint disables Auto Upgrade for given database. + x-mint: + href: /devops/developer-api/redis/disable_autoscaling + operationId: disableAutoUpgrade + parameters: + - name: id + in: path + description: The ID of the database to disable auto upgrade + required: true + schema: + type: string + responses: + "200": + description: Auto upgrade disabled successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /redis/change-plan/{id}: + post: + tags: + - redis + summary: Change Database Plan + description: This endpoint changes the plan of a Redis database. + x-mint: + href: /devops/developer-api/redis/change_plan + operationId: changePlan + parameters: + - name: id + in: path + description: The ID of the database whose plan will be changed + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/ChangePlanRequest" + responses: + "200": + description: Plan changed successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /redis/update-budget/{id}: + patch: + tags: + - redis + summary: Update Database Budget + description: This endpoint updates the monthly budget of a Redis database. + x-mint: + href: /devops/developer-api/redis/update_budget + operationId: updateBudget + parameters: + - name: id + in: path + description: The ID of the database whose budget will be updated + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + budget: + type: integer + description: The new monthly budget for the database + required: + - budget + responses: + "200": + description: Budget updated successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /redis/update-regions/{id}: + post: + tags: + - redis + summary: Update Regions (Global) + description: Update the regions of global database + x-mint: + href: /devops/developer-api/redis/update_regions + operationId: updateRegions + parameters: + - name: id + in: path + description: The ID of your database + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + read_regions: + type: array + items: + type: string + description: Array of read regions of the database + required: + - read_regions + responses: + "200": + description: Regions updated successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /redis/move-to-team: + post: + tags: + - redis + summary: Move To Team + description: This endpoint moves database under a target team + x-mint: + href: /devops/developer-api/redis/moveto_team + operationId: moveToTeam + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + team_id: + type: string + description: The ID of the target team + database_id: + type: string + description: The ID of the database to be moved + required: + - team_id + - database_id + responses: + "200": + description: Database moved successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /redis/stats/{id}: + get: + tags: + - redis + summary: Get Database Stats + description: This endpoint gets detailed stats of a database. + x-mint: + href: /devops/developer-api/redis/get_database_stats + operationId: getDatabaseStats + parameters: + - name: id + in: path + description: The ID of the database + required: true + schema: + type: string + responses: + "200": + description: Database stats retrieved successfully + content: + application/json: + schema: + $ref: "#/components/schemas/DatabaseStats" + security: + - basicAuth: [] + /redis/list-backup/{id}: + get: + tags: + - redis + summary: List Backup + description: This endpoint lists all backups for a Redis database. + x-mint: + href: /devops/developer-api/redis/backup/list_backup + operationId: listBackup + parameters: + - name: id + in: path + description: The ID of the Redis database + required: true + schema: + type: string + responses: + "200": + description: Backups retrieved successfully + content: + application/json: + schema: + type: array + items: + $ref: "#/components/schemas/Backup" + security: + - basicAuth: [] + /redis/create-backup/{id}: + post: + tags: + - redis + summary: Create Backup + description: This endpoint creates a backup for a Redis database. + x-mint: + href: /devops/developer-api/redis/backup/create_backup + operationId: createBackup + parameters: + - name: id + in: path + description: The ID of the Redis database + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + name: + type: string + description: Name of the backup + required: + - name + responses: + "200": + description: Backup created successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /redis/delete-backup/{id}/{backup_id}: + delete: + tags: + - redis + summary: Delete Backup + description: This endpoint deletes a backup of a Redis database. + x-mint: + href: /devops/developer-api/redis/backup/delete_backup + operationId: deleteBackup + parameters: + - name: id + in: path + description: The ID of the Redis database + required: true + schema: + type: string + - name: backup_id + in: path + description: The ID of the backup to delete + required: true + schema: + type: string + responses: + "200": + description: Backup deleted successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /redis/restore-backup/{id}: + post: + tags: + - redis + summary: Restore Backup + description: This endpoint restores data from an existing backup. + x-mint: + href: /devops/developer-api/redis/backup/restore_backup + operationId: restoreBackup + parameters: + - name: id + in: path + description: The ID of the Redis database + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + backup_id: + type: string + description: ID of the backup to restore + required: + - backup_id + responses: + "200": + description: Backup restored successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /redis/enable-dailybackup/{id}: + patch: + tags: + - redis + summary: Enable Daily Backup + description: This endpoint enables daily backup for a Redis database. + x-mint: + href: /devops/developer-api/redis/backup/enable_dailybackup + operationId: enableDailyBackup + parameters: + - name: id + in: path + description: The ID of the Redis database + required: true + schema: + type: string + responses: + "200": + description: Daily backup enabled successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /redis/disable-dailybackup/{id}: + patch: + tags: + - redis + summary: Disable Daily Backup + description: This endpoint disables daily backup for a Redis database. + x-mint: + href: /devops/developer-api/redis/backup/disable_dailybackup + operationId: disableDailyBackup + parameters: + - name: id + in: path + description: The ID of the Redis database + required: true + schema: + type: string + responses: + "200": + description: Daily backup disabled successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /teams: + get: + tags: + - teams + summary: List Teams + x-mint: + href: /devops/developer-api/teams/list_teams + description: This endpoint lists all teams of user. + operationId: listTeams + responses: + "200": + description: Teams retrieved successfully + content: + application/json: + schema: + type: array + items: + $ref: "#/components/schemas/Team" + security: + - basicAuth: [] + /team: + post: + tags: + - teams + summary: Create Team + x-mint: + href: /devops/developer-api/teams/create_team + description: This endpoint creates a new team. + operationId: createTeam + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/CreateTeamRequest" + responses: + "200": + description: Team created successfully + content: + application/json: + schema: + $ref: "#/components/schemas/Team" + security: + - basicAuth: [] + /team/{id}: + delete: + tags: + - teams + summary: Delete Team + x-mint: + href: /devops/developer-api/teams/delete_team + description: This endpoint deletes a team. + operationId: deleteTeam + parameters: + - name: id + in: path + description: The ID of the team to delete + required: true + schema: + type: string + responses: + "200": + description: Team deleted successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /teams/{team_id}: + get: + tags: + - teams + summary: Get Team Members + description: This endpoint list all members of a team. + x-mint: + href: /devops/developer-api/teams/get_team_members + operationId: getTeamMembers + parameters: + - name: team_id + in: path + description: ID of the team + required: true + schema: + type: string + responses: + "200": + description: Team members retrieved successfully + content: + application/json: + schema: + type: array + items: + $ref: "#/components/schemas/TeamMember" + security: + - basicAuth: [] + /teams/member: + post: + tags: + - teams + summary: Add Team Member + description: This endpoint adds a new team member to the specified team. + x-mint: + href: /devops/developer-api/teams/add_team_member + operationId: addTeamMember + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/AddTeamMemberRequest" + responses: + "200": + description: Team member added successfully + content: + application/json: + schema: + $ref: "#/components/schemas/TeamMember" + security: + - basicAuth: [] + delete: + tags: + - teams + summary: Delete Team Member + description: This endpoint deletes a team member from the specified team. + x-mint: + href: /devops/developer-api/teams/delete_team_member + operationId: deleteTeamMember + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/DeleteTeamMemberRequest" + responses: + "200": + description: Team member deleted successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /vector/index: + get: + tags: + - vector + summary: List Indices + description: This endpoint returns the data related to all indices of an account as a list. + x-mint: + href: /devops/developer-api/vector/list_indices + operationId: listIndices + responses: + "200": + description: Indices retrieved successfully + content: + application/json: + schema: + type: array + items: + $ref: "#/components/schemas/VectorIndex" + security: + - basicAuth: [] + post: + tags: + - vector + summary: Create Index + description: This endpoint creates an index. + x-mint: + href: /devops/developer-api/vector/create_index + operationId: createIndex + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/CreateIndexRequest" + responses: + "200": + description: Index created successfully + content: + application/json: + schema: + $ref: "#/components/schemas/VectorIndex" + security: + - basicAuth: [] + /vector/index/{id}: + get: + tags: + - vector + summary: Get Index + description: This endpoint returns the data associated to a index. + x-mint: + href: /devops/developer-api/vector/get_index + operationId: getIndex + parameters: + - name: id + in: path + description: The unique ID of the index to fetch + required: true + schema: + type: string + responses: + "200": + description: Index retrieved successfully + content: + application/json: + schema: + $ref: "#/components/schemas/VectorIndex" + security: + - basicAuth: [] + delete: + tags: + - vector + summary: Delete Index + description: This endpoint deletes an index. + x-mint: + href: /devops/developer-api/vector/delete_index + operationId: deleteIndex + parameters: + - name: id + in: path + description: The unique ID of the index to be deleted + required: true + schema: + type: string + responses: + "200": + description: Index deleted successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /vector/index/{id}/rename: + post: + tags: + - vector + summary: Rename Index + description: This endpoint is used to change the name of an index. + x-mint: + href: /devops/developer-api/vector/rename_index + operationId: renameIndex + parameters: + - name: id + in: path + description: The unique ID of the index to be renamed + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + name: + type: string + description: The new name of the index + required: + - name + responses: + "200": + description: Index renamed successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /vector/index/{id}/reset-password: + post: + tags: + - vector + summary: Reset Index Passwords + description: This endpoint is used to reset regular and readonly tokens of an index. + x-mint: + href: /devops/developer-api/vector/reset_index_passwords + operationId: resetIndexPasswords + parameters: + - name: id + in: path + description: The unique ID of the index to reset the password for + required: true + schema: + type: string + responses: + "200": + description: Index passwords reset successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /vector/index/{id}/setplan: + post: + tags: + - vector + summary: Set Index Plan + description: This endpoint is used to change the plan of an index. + x-mint: + href: /devops/developer-api/vector/set_index_plan + operationId: setIndexPlan + parameters: + - name: id + in: path + description: The unique ID of the index to change plan for + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + target_plan: + type: string + description: The new plan for the index + enum: + - payg + - fixed + required: + - target_plan + responses: + "200": + description: Index plan changed successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] + /vector/index/{id}/transfer: + post: + tags: + - vector + summary: Transfer Index + description: This endpoint is used to transfer an index to another team. + x-mint: + href: /devops/developer-api/vector/transfer_index + operationId: transferIndex + parameters: + - name: id + in: path + description: The unique ID of the index to be transferred + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + target_account: + type: string + description: The ID of the target account. If the target is a team, then use the format `team:`, else if the target is your personal account use the format ``. + example: "team:team-id-1" + required: + - target_account + responses: + "200": + description: Index transferred successfully + content: + application/json: + schema: + type: string + example: "OK" + security: + - basicAuth: [] +components: + schemas: + Database: + type: object + properties: + database_id: + type: string + description: ID of the database + example: 96ad0856-03b1-4ee7-9666-e81abd0349e1 + database_name: + type: string + description: Name of the database + example: MyRedis + database_type: + type: string + description: Type of the database in terms of pricing model + example: Pay as You Go + enum: + - Free + - Pay as You Go + - Enterprise + region: + type: string + description: The region where database is hosted + example: eu-central-1 + port: + type: integer + description: Database port for clients to connect + format: int64 + example: 30143 + creation_time: + type: integer + description: Creation time of the database as Unix time + format: int64 + example: 1658909671 + state: + type: string + description: State of database + example: active + enum: + - active + - deleted + password: + type: string + description: Password of the database + example: 038a8e27c45e43068d5f186085399884 + user_email: + type: string + description: Email or team id of the owner of the database + example: example@upstash.com + endpoint: + type: string + description: Endpoint URL of the database + example: eu2-sought-mollusk-30143.upstash.io + tls: + type: boolean + description: TLS/SSL is enabled or not + example: true + rest_token: + type: string + description: Token for rest based communication with the database + example: AXW_ASQgOTZhZDA4NTYtMDNiMS00ZWU3LTk2NjYtZTgxYWJkMDM0OWUxMDM4YThlMjdjNDVlNDMwNjhkNWYxODYwODUzOTk4ODQ= + read_only_rest_token: + type: string + description: Read only token for rest based communication with the database + example: AnW_ASQgOTZhZDA4NTYtMDNiMS00ZWU3LTk2NjYtZTgxYWJkMDM0OWUx8sbmiEcMm9u7Ks5Qx-kHNiWr_f-iUXSIH8MlziKMnpY= + db_max_clients: + type: integer + description: Max number of concurrent clients can be opened on this database currently + format: int64 + example: 1000 + db_max_request_size: + type: integer + description: Max size of a request that will be accepted by the database currently(in bytes) + format: int64 + example: 1048576 + db_disk_threshold: + type: integer + description: Total disk size limit that can be used for the database currently(in bytes) + format: int64 + example: 268435456 + db_max_entry_size: + type: integer + description: Max size of an entry that will be accepted by the database currently(in bytes) + format: int64 + example: 104857600 + db_memory_threshold: + type: integer + description: Max size of a memory the database can use(in bytes) + format: int64 + example: 268435456 + db_daily_bandwidth_limit: + type: integer + description: Max daily bandwidth can be used by the database(in bytes) + format: int64 + example: 53687091200 + db_max_commands_per_second: + type: integer + description: Max number of commands can be sent to the database per second + format: int64 + example: 1000 + db_request_limit: + type: integer + description: Total number of commands can be sent to the database + format: int64 + example: 10000 + cluster_id: + type: string + description: Cluster ID of the database + pool_id: + type: string + description: Pool ID of the database + type: + type: string + description: Payment plan of the database + example: paid + budget: + type: integer + description: Allocated monthly budget for the database + format: int64 + primary_region: + type: string + description: Primary region of the database cluster + primary_members: + type: array + items: + type: string + description: List of primary regions in the database cluster + all_members: + type: array + items: + type: string + description: List of all regions in the database cluster + eviction: + type: boolean + description: Entry eviction is enabled + auto_upgrade: + type: boolean + description: Automatic upgrade capability is enabled + consistent: + type: boolean + description: Strong consistency mode is enabled + reserved_per_region_price: + type: integer + description: Reserved price per region for enterprise plans + format: int64 + next_daily_backup_time: + type: integer + description: Unix timestamp of next scheduled backup + format: int64 + modifying_state: + type: string + description: Current modifying state of the database + db_resource_size: + type: string + description: Resource allocation tier + db_type: + type: string + description: Database storage engine type + db_conn_idle_timeout: + type: integer + description: Connection idle timeout in nanoseconds + format: int64 + db_lua_timeout: + type: integer + description: Lua script execution timeout in nanoseconds + format: int64 + db_lua_credits_per_min: + type: integer + description: Lua script execution credits per minute + format: int64 + db_store_max_idle: + type: integer + description: Store connection idle timeout in nanoseconds + format: int64 + db_max_loads_per_sec: + type: integer + description: Maximum load operations per second + format: int64 + db_acl_enabled: + type: boolean + description: Access Control List is enabled + db_acl_default_user_status: + type: boolean + description: Default user access status in ACL + db_eviction: + type: boolean + description: Database-level eviction policy status + xml: + name: database + CreateDatabaseRequest: + type: object + properties: + name: + type: string + description: Name of the database + example: "myredis" + region: + type: string + description: Region of the database. Only valid option is 'global'. + enum: + - global + default: "global" + example: "global" + primary_region: + type: string + description: Primary Region of the Global Database + enum: + - us-east-1 + - us-west-1 + - us-west-2 + - eu-west-1 + - eu-central-1 + - ap-southeast-1 + - ap-southeast-2 + - sa-east-1 + example: "us-east-1" + read_regions: + type: array + items: + type: string + enum: + - us-east-1 + - us-west-1 + - us-west-2 + - eu-west-1 + - eu-central-1 + - ap-southeast-1 + - ap-southeast-2 + - ap-northeast-1 + - sa-east-1 + description: Array of Read Regions of the Database + example: ["us-west-1", "us-west-2"] + plan: + type: string + description: | + Specifies the fixed plan type for the database. + If omitted, the database defaults to either the pay-as-you-go or free plan, based on the account type. + enum: + - payg + - fixed_250mb + - fixed_1gb + - fixed_5gb + - fixed_10gb + - fixed_50gb + - fixed_100gb + - fixed_500gb + example: "payg" + budget: + type: integer + description: Monthly budget of the database + example: 100 + required: + - name + - region + - primary_region + + ChangePlanRequest: + type: object + properties: + plan_name: + type: string + description: The new plan for the database + enum: + - payg + - fixed_250mb + - fixed_1gb + - fixed_5gb + - fixed_10gb + - fixed_50gb + - fixed_100gb + - fixed_500gb + example: "fixed_1gb" + auto_upgrade: + type: boolean + description: Whether to enable automatic upgrade for the database + example: true + prod_pack_enabled: + type: boolean + description: Whether to enable the production pack for the database + example: false + required: + - plan_name + DatabaseStats: + type: object + properties: + connection_count: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Connection count over time + keyspace: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Total number of keys in the database over time + throughput: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Throughput on database connections over time + produce_throughput: + type: array + nullable: true + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Write throughput over time + consume_throughput: + type: array + nullable: true + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Read throughput over time + diskusage: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Disk usage over time + latencymax: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Maximum latency over time + latencymin: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Minimum latency over time + read_latency_mean: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Average read latency over time + read_latency_99: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: 99th percentile read latency over time + latencymean: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Average latency over time + write_latency_mean: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Average write latency over time + write_latency_99: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: 99th percentile write latency over time + hits: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Cache hits over time + misses: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Cache misses over time + read: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Read requests over time + write: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Write requests over time + dailyrequests: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Daily requests over time + dailybandwidth: + type: integer + description: Total daily bandwidth usage in bytes + example: 50444740913 + bandwidths: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Bandwidth usage over time + days: + type: array + items: + type: string + description: Days of the week for measurement + example: ["Thursday", "Friday", "Saturday", "Sunday", "Monday"] + dailybilling: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Daily billing amounts over time + dailyproduce: + type: integer + nullable: true + description: Total number of daily produced commands + example: 0 + dailyconsume: + type: integer + nullable: true + description: Total number of daily consumed commands + example: 0 + total_monthly_requests: + type: integer + description: Total requests in current month + example: 1283856937 + total_monthly_read_requests: + type: integer + description: Total read requests in current month + example: 1034567002 + total_monthly_write_requests: + type: integer + description: Total write requests in current month + example: 249289935 + total_monthly_storage: + type: integer + description: Total storage used in current month (bytes) + example: 445942383672 + total_monthly_billing: + type: number + format: float + description: Total cost in current month + example: 222.33902763855485 + total_monthly_produce: + type: integer + description: Total produce commands in current month + example: 0 + total_monthly_consume: + type: integer + description: Total consume commands in current month + example: 0 + TimeSeriesData: + type: object + properties: + x: + type: string + description: Timestamp when measurement was taken + example: "2023-05-22 10:59:23.426 +0000 UTC" + y: + type: number + description: The measured value + example: 320 + required: + - x + - y + Backup: + type: object + properties: + database_id: + type: string + description: ID of the database + example: "6gceaafd-9627-4fa5-8g71-b3359g19a5g4" + customer_id: + type: string + description: Customer ID + example: "customer_id" + name: + type: string + description: Name of the backup + example: "test2" + backup_id: + type: string + description: ID of the backup + example: "1768e55b-c137-4339-b46e-449dcd33a62e" + creation_time: + type: integer + description: Creation time of the backup as Unix time + format: int64 + example: 1720186545 + state: + type: string + description: State of the backup + example: "completed" + backup_size: + type: integer + description: Size of the backup + format: int64 + example: 0 + daily_backup: + type: boolean + description: Daily backup status + example: false + hourly_backup: + type: boolean + description: Hourly backup status + example: false + xml: + name: backup + Team: + type: object + properties: + team_id: + type: string + description: ID of the team + example: "95849b27-40d0-4532-8695-d2028847f823" + team_name: + type: string + description: Name of the team + example: "test_team_name" + copy_cc: + type: boolean + description: Whether creditcard information added to team during creation or not + example: true + xml: + name: team + TeamMember: + type: object + properties: + team_id: + type: string + description: ID of the team + example: "3423cb72-e50d-43ec-a9c0-f0f359941223" + team_name: + type: string + description: Name of the team + example: "test_team_name_2" + member_email: + type: string + description: Email of the team member + example: "example@upstash.com" + member_role: + type: string + description: Role of the team member + enum: + - owner + - admin + - dev + - finance + example: "dev" + xml: + name: teamMember + CreateTeamRequest: + type: object + properties: + team_name: + type: string + description: Name of the new team + example: "myteam" + copy_cc: + type: boolean + description: Whether to copy existing credit card information to team or not + example: true + required: + - team_name + - copy_cc + AddTeamMemberRequest: + type: object + properties: + team_id: + type: string + description: Id of the team to add the member to + example: "95849b27-40d0-4532-8695-d2028847f823" + member_email: + type: string + description: Email of the new team member + example: "example@upstash.com" + member_role: + type: string + description: Role of the new team member + enum: + - admin + - dev + - finance + example: "dev" + required: + - team_id + - member_email + - member_role + DeleteTeamMemberRequest: + type: object + properties: + team_id: + type: string + description: Id of the team to remove the member from + example: "95849b27-40d0-4532-8695-d2028847f823" + member_email: + type: string + description: Email of the team member to remove + example: "example@upstash.com" + required: + - team_id + - member_email + VectorIndex: + type: object + properties: + customer_id: + type: string + description: The associated ID of the owner of the index + example: "test@upstash.com" + id: + type: string + description: Unique ID of the index + example: "0639864f-ece6-429c-8118-86a287b0e808" + name: + type: string + description: The name of the index + example: "myindex" + similarity_function: + type: string + description: Similarity function that's used to calculate the distance between two vectors + enum: + - COSINE + - EUCLIDIAN + - DOT_PRODUCT + example: "COSINE" + dimension_count: + type: number + description: The amount of values in a single vector + example: 5 + embedding_model: + type: string + description: The predefined embedding model to vectorize your plain text + enum: + - BGE_SMALL_EN_V1_5 + - BGE_BASE_EN_V1_5 + - BGE_LARGE_EN_V1_5 + - BGE_M3 + - BERT_BASE_UNCASED + - UAE_Large_V1 + - ALL_MINILM_L6_V2 + - MXBAI_EMBED_LARGE_V1 + example: "BGE_SMALL_EN_V1_5" + endpoint: + type: string + description: The REST endpoint of the index + example: "test-index-3814-eu1-vector.upstash.io" + token: + type: string + description: The REST authentication token for the index + example: "QkZGMk5heGltdW0tdXBkYXRlZC0zNzM1LWV1MkFkbWlOeGZGZ1J5Wm1GdE5tTXhNQzB1TmpsbExUb3hOekF0TVRJbFpqMTJORFUxTm1GZw==" + read_only_token: + type: string + description: The REST authentication read only token for the index + example: "QkZGRk1heGltdW0tdXBkYXRlZC0zNzM1LWV1MnJlYWRvbmx5TmtaZ05qS3JNWVV0Wm1aZ01pMDBOV1poTHRob05qY3RNR0U0TkRjejNqazJU" + type: + type: string + description: The payment plan of the index + enum: + - payg + - fixed + - paid + example: "paid" + region: + type: string + description: The region where the index is currently deployed + enum: + - eu-west-1 + - us-east-1 + example: "eu-west-1" + max_vector_count: + type: number + description: The number of maximum that your index can contain + example: 400000000 + max_daily_updates: + type: number + description: The number of maximum update operations you can perform in a day. Only upsert operations are included in update count. + example: -1 + max_daily_queries: + type: number + description: The number of maximum query operations you can perform in a day. Only query operations are included in query count. + example: -1 + max_monthly_bandwidth: + type: number + description: The maximum amount of monthly bandwidth for the index. Unit is bytes. -1 if the limit is unlimited. + example: -1 + max_writes_per_second: + type: number + description: The number of maximum write operations you can perform per second. Only upsert operations are included in write count. + example: 1000 + max_query_per_second: + type: number + description: The number of maximum query operations you can perform per second. Only query operations are included in query count. + example: 1000 + max_reads_per_request: + type: number + description: The number of maximum vectors in a read operation. Query and fetch operations are included in read operations. + example: 1000 + max_writes_per_request: + type: number + description: The number of maximum vectors in a write operation. Only upsert operations are included in write operations. + example: 1000 + max_total_metadata_size: + type: number + description: The amount of maximum size for the total metadata sizes in your index. + example: 53687091200 + reserved_price: + type: number + description: Monthly pricing of your index. Only available for fixed and pro plans. + example: 25.99 + creation_time: + type: number + description: The creation time of the vector index in UTC as unix timestamp. + example: 1707313165 + xml: + name: vectorIndex + CreateIndexRequest: + type: object + properties: + name: + type: string + description: Name of the index + example: "myindex" + region: + type: string + description: Region of the database + enum: + - eu-west-1 + - us-east-1 + example: "us-east-1" + similarity_function: + type: string + description: Similarity function that's used to calculate the distance between two vectors + enum: + - COSINE + - EUCLIDIAN + - DOT_PRODUCT + example: "COSINE" + dimension_count: + type: number + description: The amount of values in a single vector + example: 1536 + type: + type: string + description: The payment plan of your index + enum: + - payg + - fixed + - paid + example: "payg" + embedding_model: + type: string + description: The embedding model to use for the index + enum: + - BGE_SMALL_EN_V1_5 + - BGE_BASE_EN_V1_5 + - BGE_LARGE_EN_V1_5 + - BGE_M3 + - BERT_BASE_UNCASED + - UAE_Large_V1 + - ALL_MINILM_L6_V2 + - MXBAI_EMBED_LARGE_V1 + example: "BGE_SMALL_EN_V1_5" + required: + - name + - region + - similarity_function + - dimension_count + ApiResponse: + type: object + properties: + code: + type: integer + format: int32 + type: + type: string + message: + type: string + xml: + name: "##default" + Error: + type: object + properties: + code: + type: string + message: + type: string + required: + - code + - message + securitySchemes: + basicAuth: + type: http + scheme: basic diff --git a/devops/developer-api/redis/autoscaling.mdx b/devops/developer-api/redis/autoscaling.mdx deleted file mode 100644 index e69de29b..00000000 diff --git a/devops/developer-api/redis/backup/create_backup.mdx b/devops/developer-api/redis/backup/create_backup.mdx deleted file mode 100644 index 57e87c6b..00000000 --- a/devops/developer-api/redis/backup/create_backup.mdx +++ /dev/null @@ -1,64 +0,0 @@ ---- -title: "Create Backup" -description: "This endpoint creates a backup for a Redis database." -api: "POST https://api.upstash.com/v2/redis/create-backup/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the Redis database - - -## Request Parameters - - - Name of the backup - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/create-backup/{id} \ - -u 'EMAIL:API_KEY' \ - -d '{"name" : "backup_name"}' -``` - -```python Python -import requests - -data = '{"name" : "backup_name"}' - -response = requests.post('https://api.upstash.com/v2/redis/create-backup/{id}', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "name":"backup_name" -}`) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/create-backup/{id}", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s -", bodyText); -``` - - - -```json 200 OK -"OK" -``` - diff --git a/devops/developer-api/redis/backup/delete_backup.mdx b/devops/developer-api/redis/backup/delete_backup.mdx deleted file mode 100644 index ab0d2d02..00000000 --- a/devops/developer-api/redis/backup/delete_backup.mdx +++ /dev/null @@ -1,56 +0,0 @@ ---- -title: "Delete Backup" -description: "This endpoint deletes a backup of a Redis database." -api: "DELETE https://api.upstash.com/v2/redis/delete-backup/{id}/{backup_id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the Redis database - - - - The ID of the backup to delete - - - -```shell curl -curl -X DELETE \ - https://api.upstash.com/v2/redis/delete-backup/:id/:backup_id \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.delete('https://api.upstash.com/v2/redis/delete-backup/:id/:backup_id', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("DELETE", "https://api.upstash.com/v2/redis/delete-backup/:id/:backup_id", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s -", bodyText); -``` - - - -```json 200 OK -"OK" -``` - \ No newline at end of file diff --git a/devops/developer-api/redis/backup/disable_dailybackup.mdx b/devops/developer-api/redis/backup/disable_dailybackup.mdx deleted file mode 100644 index a6a69c47..00000000 --- a/devops/developer-api/redis/backup/disable_dailybackup.mdx +++ /dev/null @@ -1,52 +0,0 @@ ---- -title: "Disable Daily Backup" -description: "This endpoint disables daily backup for a Redis database." -api: "PATCH https://api.upstash.com/v2/redis/disable-dailybackup/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the Redis database - - - -```shell curl -curl -X PATCH \ - https://api.upstash.com/v2/redis/disable-dailybackup/{id} \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.patch('https://api.upstash.com/v2/redis/disable-dailybackup/{id}', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("PATCH", "https://api.upstash.com/v2/redis/disable-dailybackup/{id}", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s -", bodyText); -``` - - - -```json 200 OK -"OK" -``` - \ No newline at end of file diff --git a/devops/developer-api/redis/backup/enable_dailybackup.mdx b/devops/developer-api/redis/backup/enable_dailybackup.mdx deleted file mode 100644 index e9c592ab..00000000 --- a/devops/developer-api/redis/backup/enable_dailybackup.mdx +++ /dev/null @@ -1,52 +0,0 @@ ---- -title: "Enable Daily Backup" -description: "This endpoint enables daily backup for a Redis database." -api: "PATCH https://api.upstash.com/v2/redis/enable-dailybackup/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the Redis database - - - -```shell curl -curl -X PATCH \ - https://api.upstash.com/v2/redis/enable-dailybackup/{id} \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.patch('https://api.upstash.com/v2/redis/enable-dailybackup/{id}', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("PATCH", "https://api.upstash.com/v2/redis/enable-dailybackup/{id}", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s -", bodyText); -``` - - - -```json 200 OK -"OK" -``` - \ No newline at end of file diff --git a/devops/developer-api/redis/backup/list_backup.mdx b/devops/developer-api/redis/backup/list_backup.mdx deleted file mode 100644 index aaaf7514..00000000 --- a/devops/developer-api/redis/backup/list_backup.mdx +++ /dev/null @@ -1,105 +0,0 @@ ---- -title: "List Backup" -description: "This endpoint lists all backups for a Redis database." -api: "GET https://api.upstash.com/v2/redis/list-backup/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the Redis database - - -## Response Parameters - - - ID of the database - - - Customer ID - - - Name of the backup - - - ID of the backup - - - Creation time of the backup as Unix time - - - State of the backup (e.g., completed) - - - Size of the backup - - - Daily backup status - - - Hourly backup status - - - -```shell curl -curl -X GET \ - https://api.upstash.com/v2/redis/list-backup/{id} \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.get('https://api.upstash.com/v2/redis/list-backup/{id}', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("GET", "https://api.upstash.com/v2/redis/list-backup/{id}", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s -", bodyText); -``` - - - -```json 200 OK -[ - { - "database_id":"6gceaafd-9627-4fa5-8g71-b3359g19a5g4", - "customer_id":"customer_id", - "name":"test2", - "backup_id":"1768e55b-c137-4339-b46e-449dcd33a62e", - "creation_time":1720186545, - "state":"completed", - "backup_size":0, - "daily_backup":"false", - "hourly_backup":"false" - }, - { - "database_id":"6gceaafd-9627-4fa5-8g71-b3359g19a5g4", - "customer_id":"customer_id", - "name":"test1", - "backup_id":"39310b84-21b3-45c3-5318-403553a2466d", - "creation_time":1720096600, - "state":"completed", - "backup_size":0, - "daily_backup":"false", - "hourly_backup":"false" - } -] -``` - diff --git a/devops/developer-api/redis/backup/restore_backup.mdx b/devops/developer-api/redis/backup/restore_backup.mdx deleted file mode 100644 index 5ab1a3eb..00000000 --- a/devops/developer-api/redis/backup/restore_backup.mdx +++ /dev/null @@ -1,64 +0,0 @@ ---- -title: "Restore Backup" -description: "This endpoint restores data from an existing backup." -api: "POST https://api.upstash.com/v2/redis/restore-backup/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the Redis database - - -## Request Parameters - - - ID of the backup to restore - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/restore-backup/{id} \ - -u 'EMAIL:API_KEY' - -d '{"backup_id" : "backup_id"}' -``` - -```python Python -import requests - -data = '{"backup_id" : "backup_id"}' - -response = requests.post('https://api.upstash.com/v2/redis/restore-backup/{id}', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "backup_id":"backup_id" -}`) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/restore-backup/{id}", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s -", bodyText); -``` - - - -```json 200 OK -"OK" -``` - \ No newline at end of file diff --git a/devops/developer-api/redis/change_plan.mdx b/devops/developer-api/redis/change_plan.mdx deleted file mode 100644 index 379abb43..00000000 --- a/devops/developer-api/redis/change_plan.mdx +++ /dev/null @@ -1,75 +0,0 @@ ---- -title: "Change Database Plan" -description: "This endpoint changes the plan of a Redis database." -api: "POST https://api.upstash.com/v2/redis/change-plan/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the database whose plan will be changed. - - -## Request Parameters - - - The new plan for the database.
- Available options: payg, fixed_250mb, fixed_1gb, fixed_5gb, fixed_10gb, fixed_50gb, fixed_100gb, fixed_500gb -
- - (Optional) Whether to enable automatic upgrade for the database. - - - (Optional) Whether to enable the production pack for the database. - - -> **Note:** If you do not want to change `auto_upgrade` or `prod_pack_enabled`, simply omit those fields from the request payload. - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/change-plan/:id \ - -u 'EMAIL:API_KEY' \ - -d '{"plan_name": "fixed_1gb", "auto_upgrade": true, "prod_pack_enabled": false}' -``` - -```python Python -import requests - -data = '{"plan_name": "fixed_1gb", "auto_upgrade": true, "prod_pack_enabled": false}' -response = requests.post('https://api.upstash.com/v2/redis/change-plan/:id', data=data, auth=('EMAIL', 'API_KEY')) -print(response.content) -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "plan_name": "fixed_1gb", - "auto_upgrade": true, - "prod_pack_enabled": false -}`) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/change-plan/:id", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText) -``` - - - - -```json 200 OK -"OK" -``` - \ No newline at end of file diff --git a/devops/developer-api/redis/create_database.mdx b/devops/developer-api/redis/create_database.mdx deleted file mode 100644 index 35624d82..00000000 --- a/devops/developer-api/redis/create_database.mdx +++ /dev/null @@ -1,121 +0,0 @@ ---- -title: "Create a Redis Database (Regional - DEPRECATED)" -description: "This endpoint creates a new regional Redis database. -This behaviour is deprecated in favor of Global databases and support for it will be removed in the upcoming releases." -api: "POST https://api.upstash.com/v2/redis/database" -authMethod: "basic" ---- - -## Request Parameters - - - Name of the database - - - Region of the database.\ **Options:** `eu-west-1`, `us-east-1`, `us-west-1`, - `ap-northeast-1` or `us-central1` - - - - Set true to enable tls. - - -## Response Parameters - - - ID of the created database - - - Name of the database - - - Type of the database in terms of pricing model(Free, Pay as You Go or - Enterprise) - - - The region where database is hosted - - - Database port for clients to connect - - - Creation time of the database as Unix time - - - State of database (active or deleted) - - - Password of the database - - - Email or team id of the owner of the database - - - Endpoint URL of the database - - - TLS/SSL is enabled or not - - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/database \ - -u 'EMAIL:API_KEY' \ - -d '{"name":"myredis","region":"eu-west-1","tls": true}' -``` - -```python Python -import requests - -data = '{"name":"myredis","region":"eu-west-1","tls":true}' - -response = requests.post('https://api.upstash.com/v2/redis/database', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "name":"myredis", - "region":"eu-west-1", - "tls": true -}`) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/database", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -{ - "database_id": "96ad0856-03b1-4ee7-9666-e81abd0349e1", - "database_name": "MyRedis", - "database_type": "Pay as You Go", - "region": "eu-central-1", - "port": 30143, - "creation_time": 1658909671, - "state": "active", - "password": "038a8e27c45e43068d5f186085399884", - "user_email": "example@upstash.com", - "endpoint": "eu2-sought-mollusk-30143.upstash.io", - "tls": true, - "rest_token": "AXW_ASQgOTZhZDA4NTYtMDNiMS00ZWU3LTk2NjYtZTgxYWJkMDM0OWUxMDM4YThlMjdjNDVlNDMwNjhkNWYxODYwODUzOTk4ODQ=", - "read_only_rest_token": "AnW_ASQgOTZhZDA4NTYtMDNiMS00ZWU3LTk2NjYtZTgxYWJkMDM0OWUx8sbmiEcMm9u7Ks5Qx-kHNiWr_f-iUXSIH8MlziKMnpY=" -} -``` - diff --git a/devops/developer-api/redis/create_database_global.mdx b/devops/developer-api/redis/create_database_global.mdx deleted file mode 100644 index 8c9c5141..00000000 --- a/devops/developer-api/redis/create_database_global.mdx +++ /dev/null @@ -1,142 +0,0 @@ ---- -title: "Create a Redis Database (Global)" -description: "This endpoint creates a new Redis database." -api: "POST https://api.upstash.com/v2/redis/database" -authMethod: "basic" ---- - -## Request Parameters - - -Name of the database - - -Region of the database. Only valid option is `global`. - - -Specifies the fixed plan type for the database. -If omitted, the database defaults to either the pay-as-you-go or free plan, based on the account type. - -Available options: `payg`, `fixed_250mb`, `fixed_1gb`, `fixed_5gb`, `fixed_10gb`, `fixed_50gb`, `fixed_100gb`, `fixed_500gb`. - - - -Primary Region of the Global Database. - -Available regions: `us-east-1`, `us-west-1`, `us-west-2`, `eu-west-1`, -`eu-central-1`, `ap-southeast-1`, `ap-southeast-2`, `sa-east-1` - - - -Array of Read Regions of -the Database. - -Available regions: `us-east-1`, `us-west-1`, `us-west-2`, `eu-west-1`, -`eu-central-1`, `ap-southeast-1`, `ap-southeast-2`, `ap-northeast-1`, `sa-east-1` - - -Monthly budget of the database - - -## Response Parameters - - - ID of the created database - - - Name of the database - - - Type of the database in terms of pricing model(Free, Pay as You Go or - Enterprise) - - - The region where database is hosted - - - Database port for clients to connect - - - Creation time of the database as Unix time - - - State of database (active or deleted) - - - Password of the database - - - Email or team id of the owner of the database - - - Endpoint URL of the database - - - TLS is always enabled for new databases - - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/database \ - -u 'EMAIL:API_KEY' \ - -d '{"name":"myredis", "region":"global", "primary_region":"us-east-1", "read_regions":["us-west-1","us-west-2"], "tls": true}' -``` - -```python Python -import requests - -data = '{"name":"myredis", "region":"global", "primary_region":"us-east-1", "read_regions":["us-west-1","us-west-2"], "tls":true}' - -response = requests.post('https://api.upstash.com/v2/redis/database', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "name":"myredis", - "region":"global", - "primary_region"":"us-east-1", - "read_regions":["us-west-1","us-west-2"], - "tls": true -}`) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/database", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -{ - "database_id": "93e3a3e-342c-4683-ba75-344c08ae143b", - "database_name": "global-test", - "database_type": "Pay as You Go", - "region": "global", - "type": "paid", - "port": 32559, - "creation_time": 1674596896, - "state": "active", - "password": "dd1803832a2746309e118373549e574d", - "user_email": "support@upstash.com", - "endpoint": "steady-stud-32559.upstash.io", - "tls": false, - "rest_token": "AX8vACQgOTMyY2UyYy00NjgzLWJhNzUtMzQ0YzA4YWUxNDNiZMyYTI3NDYzMDllMTE4MzczNTQ5ZTU3NGQ=", - "read_only_rest_token": "An8vACQg2UtMzQyYy00NjgzLWJhNzUtMzQ0YzA4YBVsUsyn19xDnTAvjbsiq79GRDrURNLzIYIOk=" -} -``` - diff --git a/devops/developer-api/redis/delete_database.mdx b/devops/developer-api/redis/delete_database.mdx deleted file mode 100644 index b295fa1a..00000000 --- a/devops/developer-api/redis/delete_database.mdx +++ /dev/null @@ -1,53 +0,0 @@ ---- -title: "Delete Database" -description: "This endpoint deletes a database." -api: "DELETE https://api.upstash.com/v2/redis/database/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the database to be deleted - - - - -```shell curl -curl -X DELETE \ - https://api.upstash.com/v2/redis/database/:id \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.delete('https://api.upstash.com/v2/redis/database/:id' auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("DELETE", "https://api.upstash.com/v2/redis/database/:id", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -"OK" -``` - diff --git a/devops/developer-api/redis/disable_autoscaling.mdx b/devops/developer-api/redis/disable_autoscaling.mdx deleted file mode 100644 index 77bfbbea..00000000 --- a/devops/developer-api/redis/disable_autoscaling.mdx +++ /dev/null @@ -1,49 +0,0 @@ ---- -title: "Disable Auto Upgrade" -description: "This endpoint disables Auto Upgrade for given database." -api: "POST https://api.upstash.com/v2/redis/disable-autoupgrade/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the database to disable auto upgrade - - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/disable-autoupgrade/:id \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.post('https://api.upstash.com/v2/redis/disable-autoupgrade/:id', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/disable-autoupgrade/:id", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - -```json 200 OK "OK" ``` diff --git a/devops/developer-api/redis/disable_eviction.mdx b/devops/developer-api/redis/disable_eviction.mdx deleted file mode 100644 index 19605d97..00000000 --- a/devops/developer-api/redis/disable_eviction.mdx +++ /dev/null @@ -1,55 +0,0 @@ ---- -title: "Disable Eviction" -description: "This endpoint disables eviction for given database." -api: "POST https://api.upstash.com/v2/redis/disable-eviction/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the database to disable eviction - - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/disable-eviction/:id \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.post('https://api.upstash.com/v2/redis/disable-eviction/:id', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/disable-eviction/:id", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - - -```json 200 OK -"OK" -``` - - diff --git a/devops/developer-api/redis/enable_autoscaling.mdx b/devops/developer-api/redis/enable_autoscaling.mdx deleted file mode 100644 index 1b47b3c4..00000000 --- a/devops/developer-api/redis/enable_autoscaling.mdx +++ /dev/null @@ -1,55 +0,0 @@ ---- -title: "Enable Auto Upgrade" -description: "This endpoint enables Auto Upgrade for given database." -api: "POST https://api.upstash.com/v2/redis/enable-autoupgrade/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the database to enable auto upgrade - - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/enable-autoupgrade/:id \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.post('https://api.upstash.com/v2/redis/enable-autoupgrade/:id', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/enable-autoupgrade/:id", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - - -```json 200 OK -"OK" -``` - - diff --git a/devops/developer-api/redis/enable_eviction.mdx b/devops/developer-api/redis/enable_eviction.mdx deleted file mode 100644 index afa68298..00000000 --- a/devops/developer-api/redis/enable_eviction.mdx +++ /dev/null @@ -1,55 +0,0 @@ ---- -title: "Enable Eviction" -description: "This endpoint enables eviction for given database." -api: "POST https://api.upstash.com/v2/redis/enable-eviction/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the database to enable eviction - - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/enable-eviction/:id \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.post('https://api.upstash.com/v2/redis/enable-eviction/:id', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/enable-eviction/:id", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - - -```json 200 OK -"OK" -``` - - diff --git a/devops/developer-api/redis/enable_tls.mdx b/devops/developer-api/redis/enable_tls.mdx deleted file mode 100644 index 32ec874b..00000000 --- a/devops/developer-api/redis/enable_tls.mdx +++ /dev/null @@ -1,103 +0,0 @@ ---- -title: "Enable TLS" -description: "This endpoint enables tls on a database." -api: "POST https://api.upstash.com/v2/redis/enable-tls/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the database to rename - - -## Response Parameters - - - ID of the created database - - - Name of the database - - - Type of the database in terms of pricing model\ `Free`, `Pay as You Go` or - `Enterprise` - - - The region where database is hosted - - - Database port for clients to connect - - - Creation time of the database as Unix time - - - State of database\ `active` or `deleted` - - - Password of the database - - - Email or team id of the owner of the database - - - Endpoint URL of the database - - - TLS/SSL is enabled or not - - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/enable-tls/:id \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.post('https://api.upstash.com/v2/redis/enable-tls/:id', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/enable-tls/:id", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -{ - "database_id": "96ad0856-03b1-4ee7-9666-e81abd0349e1", - "cluster_id": "dea1f974", - "database_name": "MyRedis", - "database_type": "Pay as You Go", - "region": "eu-central-1", - "port": 30143, - "creation_time": 1658909671, - "state": "active", - "password": "49665a1710f3434d8be008aab50f38d2", - "user_email": "example@upstash.com", - "endpoint": "eu2-sought-mollusk-30143.upstash.io", - "tls": true, -} -``` - diff --git a/devops/developer-api/redis/get_database.mdx b/devops/developer-api/redis/get_database.mdx deleted file mode 100644 index 1f8c3ba3..00000000 --- a/devops/developer-api/redis/get_database.mdx +++ /dev/null @@ -1,146 +0,0 @@ ---- -title: "Get Database" -description: "This endpoint gets details of a database." -api: "GET https://api.upstash.com/v2/redis/database/{id}" -authMethod: "basic" ---- - -## Request - - - The ID of the database to reset password - - - Set to `hide` to remove credentials from the response. - - -## Response - - - ID of the created database - - - Name of the database - - - Type of the database in terms of pricing model(Free, Pay as You Go or - Enterprise) - - - The region where database is hosted - - - Database port for clients to connect - - - Creation time of the database as Unix time - - - State of database (active or deleted) - - - Password of the database - - - Email or team id of the owner of the database - - - Endpoint URL of the database - - - TLS/SSL is enabled or not - - - Token for rest based communication with the database - - - Read only token for rest based communication with the database - - - Max number of concurrent clients can be opened on this database currently - - - Max size of a request that will be accepted by the database currently(in - bytes) - - - Total disk size limit that can be used for the database currently(in bytes) - - - Max size of an entry that will be accepted by the database currently(in bytes) - - - Max size of a memory the database can use(in bytes) - - - Max daily bandwidth can be used by the database(in bytes) - - - Max number of commands can be sent to the database per second - - - Total number of commands can be sent to the database - - - - -```shell curl -curl -X GET \ - https://api.upstash.com/v2/redis/database/:id \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.get('https://api.upstash.com/v2/redis/database/:id', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("GET", "https://api.upstash.com/v2/redis/database/:id", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -{ - "database_id": "96ad0856-03b1-4ee7-9666-e81abd0349e1", - "database_name": "MyRedis", - "database_type": "Pay as You Go", - "region": "eu-central-1", - "port": 30143, - "creation_time": 1658909671, - "state": "active", - "password": "038a8e27c45e43068d5f186085399884", - "user_email": "example@upstash.com", - "endpoint": "eu2-sought-mollusk-30143.upstash.io", - "tls": true, - "rest_token": "AXW_ASQgOTZhZDA4NTYtMDNiMS00ZWU3LTk2NjYtZTgxYWJkMDM0OWUxMDM4YThlMjdjNDVlNDMwNjhkNWYxODYwODUzOTk4ODQ=", - "read_only_rest_token": "AnW_ASQgOTZhZDA4NTYtMDNiMS00ZWU3LTk2NjYtZTgxYWJkMDM0OWUx8sbmiEcMm9u7Ks5Qx-kHNiWr_f-iUXSIH8MlziKMnpY=", - "db_max_clients": 1000, - "db_max_request_size": 1048576, - "db_disk_threshold": 107374182400, - "db_max_entry_size": 104857600, - "db_memory_threshold": 1073741824, - "db_daily_bandwidth_limit": 53687091200, - "db_max_commands_per_second": 1000, - "db_request_limit": 9223372036854775808 -} -``` - diff --git a/devops/developer-api/redis/get_database_stats.mdx b/devops/developer-api/redis/get_database_stats.mdx deleted file mode 100644 index e918e192..00000000 --- a/devops/developer-api/redis/get_database_stats.mdx +++ /dev/null @@ -1,440 +0,0 @@ ---- -title: "Get Database Stats" -description: "This endpoint gets detailed stats of a database." -api: "GET https://api.upstash.com/v2/redis/stats/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the database - - -## Response Parameters - - - - - Timestamp indicating when the measurement was taken. - - - Total number of connections momentarily - - - - - - - - Timestamp indicating when the measurement was taken. - - - Total number keys exists in the database - - - - - - - - Timestamp indicating when the measurement was taken. - - - Throughput seen on the database connections - - - - - - - - Timestamp indicating when the measurement was taken. - - - Throughput seen on the database connections for write requests - - - - - - - - Timestamp indicating when the measurement was taken. - - - Throughput seen on the database connections for read requests - - - - - - - - Timestamp indicating when the measurement was taken. - - - Total amount of this usage of the database - - - - - - - - Timestamp indicating when the measurement was taken. - - - Maximum server latency observed in the last hour - - - - - - - - Timestamp indicating when the measurement was taken. - - - Minimum server latency observed in the last hour - - - - - - - - Timestamp indicating when the measurement was taken. - - - The average read latency value measured in the last hour - - - - - - - - Timestamp indicating when the measurement was taken. - - - The 99th percentile server read latency observed in the last hour - - - - - - - - Timestamp indicating when the measurement was taken. - - - The average write latency value measured in the last hour - - - - - - - - Timestamp indicating when the measurement was taken. - - - The 99th percentile server write latency observed in the last hour - - - - - - - - Timestamp indicating when the measurement was taken. - - - Total number requests made to the database that are hit - - - - - - - - Timestamp indicating when the measurement was taken. - - - Total number requests made to the database that are miss - - - - - - - - Timestamp indicating when the measurement was taken. - - - Total number read requests made to the database - - - - - - - - Timestamp indicating when the measurement was taken. - - - Total number write requests made to the database - - - - - - - - Timestamp indicating when the measurement was taken. - - - Total number requests made to the database on the corresponding day - - - - - - The total daily bandwidth usage (in bytes). - - - - - - Timestamp indicating when the measurement was taken. - - - The total bandwidth size for that specific timestamp - - - - - - A list of the days of the week for the measurement - - - - - - Timestamp indicating when the measurement was taken. - - - The billing amount for that specific date. - - - - - - Total number of daily produced commands - - - - Total number of daily consumed commands - - - - The total number of requests made in the current month. - - - - The total number of read requests made in the current month. - - - - The total number of write requests made in the current month. - - - - The total amount of storage used (in bytes) in the current month. - - - - Total cost of the database in the current month - - - - Total number of produce commands in the current month - - - - Total number of consume commands in the current month - - - - -```shell curl -curl -X GET \ - https://api.upstash.com/v2/redis/stats/:id \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.get('https://api.upstash.com/v2/redis/stats/:id', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("GET", "https://api.upstash.com/v2/redis/stats/:id", nil) -if err != nil { -log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { -log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { -log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -{ - "connection_count": [ - { - "x": "2023-05-22 10:59:23.426 +0000 UTC", - "y": 320 - }, - ... - ], - "keyspace": [ - { - "x": "2023-05-22 10:59:23.426 +0000 UTC", - "y": 344725564 - }, - ... - ], - "throughput": [ - { - "x": "2023-05-22 11:00:23.426 +0000 UTC", - "y": 181.88333333333333 - }, - ... - ], - "produce_throughput": null, - "consume_throughput": null, - "diskusage": [ - { - "x": "2023-05-22 10:59:23.426 +0000 UTC", - "y": 532362818323 - }, - ... - ], - "latencymean": [ - { - "x": "2023-05-22 10:59:23.426 +0000 UTC", - "y": 0.176289 - }, - ... - ], - "read_latency_mean": [ - { - "x": "2023-05-22 11:00:23.426 +0000 UTC", - "y": 0 - }, - ... - ], - "read_latency_99": [ - { - "x": "2023-05-22 11:00:23.426 +0000 UTC", - "y": 0 - }, - ... - ], - "write_latency_mean": [ - { - "x": "2023-05-22 11:00:23.426 +0000 UTC", - "y": 0 - }, - ... - ], - "write_latency_99": [ - { - "x": "2023-05-22 11:00:23.426 +0000 UTC", - "y": 0 - }, - ... - ], - "hits": [ - { - "x": "2023-05-22 11:00:23.426 +0000 UTC", - "y": 0 - }, - ... - ], - "misses": [ - { - "x": "2023-05-22 11:00:23.426 +0000 UTC", - "y": 0 - }, - ... - ], - "read": [ - { - "x": "2023-05-22 11:00:23.426 +0000 UTC", - "y": 82.53333333333333 - }, - ... - ], - "write": [ - { - "x": "2023-05-22 11:00:23.426 +0000 UTC", - "y": 99.35 - }, - ... - ], - "dailyrequests": [ - { - "x": "2023-05-18 11:58:23.534505371 +0000 UTC", - "y": 68844080 - }, - ... - ], - "days": [ - "Thursday", - "Friday", - "Saturday", - "Sunday", - "Monday" - ], - "dailybilling": [ - { - "x": "2023-05-18 11:58:23.534505371 +0000 UTC", - "y": 145.72694911244588 - }, - ... - ], - "dailybandwidth": 50444740913, - "bandwidths": [ - { - "x": "2023-05-18 11:58:23.534505371 +0000 UTC", - "y": 125391861729 - }, - ... - ], - "dailyproduce": null, - "dailyconsume": null, - "total_monthly_requests": 1283856937, - "total_monthly_read_requests": 1034567002, - "total_monthly_write_requests": 249289935, - "total_monthly_storage": 445942383672, - "total_monthly_billing": 222.33902763855485, - "total_monthly_produce": 0, - "total_monthly_consume": 0 -} -``` - diff --git a/devops/developer-api/redis/list_databases.mdx b/devops/developer-api/redis/list_databases.mdx deleted file mode 100644 index 665f1616..00000000 --- a/devops/developer-api/redis/list_databases.mdx +++ /dev/null @@ -1,106 +0,0 @@ ---- -title: "List Databases" -description: "This endpoint list all databases of user." -api: "GET https://api.upstash.com/v2/redis/databases" -authMethod: "basic" ---- - -## Response Parameters - - - ID of the database - - - Name of the database - - - Type of the database in terms of pricing model\ `Free`, `Pay as You Go` or - `Enterprise` - - - The region where database is hosted - - - Database port for clients to connect - - - Creation time of the database as Unix time - - - State of database\ `active` or `deleted` - - - Password of the database - - - Email or team id of the owner of the database - - - Endpoint URL of the database - - - TLS/SSL is enabled or not - - - Token for rest based communication with the database - - - Read only token for rest based communication with the database - - - - -```shell curl -curl -X GET \ - https://api.upstash.com/v2/redis/databases \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.get('https://api.upstash.com/v2/redis/databases', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("GET", "https://api.upstash.com/v2/redis/databases", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -[ - { - "database_id": "96ad0856-03b1-4ee7-9666-e81abd0349e1", - "database_name": "MyRedis", - "database_type": "Pay as You Go", - "region": "eu-central-1", - "port": 30143, - "creation_time": 1658909671, - "state": "active", - "password": "038a8e27c45e43068d5f186085399884", - "user_email": "example@upstash.com", - "endpoint": "eu2-sought-mollusk-30143.upstash.io", - "tls": true, - "rest_token": "AXW_ASQgOTZhZDA4NTYtMDNiMS00ZWU3LTk2NjYtZTgxYWJkMDM0OWUxMDM4YThlMjdjNDVlNDMwNjhkNWYxODYwODUzOTk4ODQ=", - "read_only_rest_token": "AnW_ASQgOTZhZDA4NTYtMDNiMS00ZWU3LTk2NjYtZTgxYWJkMDM0OWUx8sbmiEcMm9u7Ks5Qx-kHNiWr_f-iUXSIH8MlziKMnpY=" - } -] -``` - diff --git a/devops/developer-api/redis/moveto_team.mdx b/devops/developer-api/redis/moveto_team.mdx deleted file mode 100644 index 7d9f23f5..00000000 --- a/devops/developer-api/redis/moveto_team.mdx +++ /dev/null @@ -1,60 +0,0 @@ ---- -title: "Move To Team" -description: "This endpoint moves database under a target team" -api: "POST https://api.upstash.com/v2/redis/move-to-team" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the target team - - - - The ID of the database to be moved - - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/move-to-team \ - -u 'EMAIL:API_KEY' \ - -d '{"team_id": "6cc32556-0718-4de5-b69c-b927693f9282","database_id": "67b6af16-acb2-4f00-9e38-f6cb9bee800d"}' -``` - -```python Python -import requests - -data = '{"team_id": "6cc32556-0718-4de5-b69c-b927693f9282","database_id": "67b6af16-acb2-4f00-9e38-f6cb9bee800d"}' - -response = requests.post('https://api.upstash.com/v2/redis/move-to-team', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "team_id": "6cc32556-0718-4de5-b69c-b927693f9282", - "database_id": "67b6af16-acb2-4f00-9e38-f6cb9bee800d" -}`) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/move-to-team", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - -```json 200 OK "OK" ``` diff --git a/devops/developer-api/redis/rename_database.mdx b/devops/developer-api/redis/rename_database.mdx deleted file mode 100644 index 82d6b402..00000000 --- a/devops/developer-api/redis/rename_database.mdx +++ /dev/null @@ -1,258 +0,0 @@ ---- -title: "Rename Database" -description: "This endpoint renames a database." -api: "POST https://api.upstash.com/v2/redis/rename/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the database to be renamed - - -## Request Parameters - - - The new name of the database - - -## Response Parameters - - - ID of the created database - - - New name of the database - - - Type of the database in terms of pricing model\ `Free`, `Pay as You Go` or - `Enterprise` - - - The region where database is hosted - - - List of primary regions in the database cluster - - - List of all regions in the database cluster - - - Primary region of the database cluster - - - Database port for clients to connect - - - Creation time of the database as Unix time - - - Allocated budget for database operations - - - State of database\ `active` or `deleted` - - - Password of the database - - - Email or team id of the owner of the database - - - Endpoint URL of the database - - - TLS/SSL is enabled or not - - - Whether entry eviction is enabled - - - Automatic upgrade capability status - - - Strong consistency mode status - - - - Reserved price per region for enterprise plans - - - - Unix timestamp of next scheduled backup - - - - Database state - - - - Full-access REST token - - - - Read-only REST token - - - - Maximum allowed concurrent client connections - - - - Maximum request size in bytes - - - - Resource allocation tier - - - - Database storage engine type - - - - Disk storage limit in bytes - - - - Maximum entry size in bytes - - - - Memory usage limit in bytes - - - - Connection idle timeout in nanoseconds - - - - Lua script execution timeout in nanoseconds - - - - Lua script execution credits per minute - - - - Store connection idle timeout in nanoseconds - - - - Maximum load operations per second - - - - Maximum commands processed per second - - - - Maximum allowed requests - - - - Database-level eviction policy status - - - - Access Control List enablement status - - - - Default user access status in ACL - - - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/rename/:id \ - -u 'EMAIL:API_KEY' - -d '{"name":"MyRedis_new_name"}' -``` - -```python Python -import requests - -data = '{"name":"MyRedis_new_name"}' -response = requests.post('https://api.upstash.com/v2/redis/rename/:id', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "name":"MyRedis_new_name" -}`) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/rename/:id", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -{ - "database_id": 96ad0856-03b1-4ee7-9666-e81abd0349e1, - "database_name": "MyRedis_new_name", - "database_type": "Pay as You Go", - "region": "global", - "type": "paid", - "primary_members": [ - "eu-central-1" - ], - "all_members": [ - "eu-central-1" - ], - "primary_region": "eu-central-1", - "port": 6379, - "creation_time": 1727087321, - "budget": 100, - "state": "active", - "password": “***”, - "user_email": “a**@upstash.com", - "endpoint": “all-foxe-22421.upstash.io", - "tls": true, - "eviction": true, - "auto_upgrade": false, - "consistent": false, - "reserved_per_region_price": 0, - "next_daily_backup_time": 1741120356, - "modifying_state": "", - "rest_token": “***”, - "read_only_rest_token": “***”, - "db_max_clients": 1000, - "db_max_request_size": 1048576, - "db_resource_size": "L", - "db_type": "pebble", - "db_disk_threshold": 107374182400, - "db_max_entry_size": 104857600, - "db_memory_threshold": 3221225472, - "db_conn_idle_timeout": 21600000000000, - "db_lua_timeout": 250000000, - "db_lua_credits_per_min": 10000000000, - "db_store_max_idle": 900000000000, - "db_max_loads_per_sec": 1000000, - "db_max_commands_per_second": 1000, - "db_request_limit": 9223372036854776000, - "db_eviction": true, - "db_acl_enabled": "false", - "db_acl_default_user_status": "true" -} -``` - -``` diff --git a/devops/developer-api/redis/reset_password.mdx b/devops/developer-api/redis/reset_password.mdx deleted file mode 100644 index f46dd221..00000000 --- a/devops/developer-api/redis/reset_password.mdx +++ /dev/null @@ -1,107 +0,0 @@ ---- -title: "Reset Password" -description: "This endpoint updates the password of a database." -api: "POST https://api.upstash.com/v2/redis/reset-password/{id}" -authMethod: "basic" ---- - -## Request - - - The ID of the database to reset password - - -## Response - - - ID of the created database - - - Name of the database - - - Type of the database in terms of pricing model\ `Free`, `Pay as You Go` or - `Enterprise` - - - The region where database is hosted - - - Database port for clients to connect - - - Creation time of the database as Unix time - - - State of database\ `active` or `deleted` - - - Password of the database - - - Email or team id of the owner of the database - - - Endpoint URL of the database - - - TLS/SSL is enabled or not - - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/reset-password/:id \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.post('https://api.upstash.com/v2/redis/reset-password/:id', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/reset-password/:id", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -{ - "database_id": "96ad0856-03b1-4ee7-9666-e81abd0349e1", - "cluster_id": "dea1f974", - "database_name": "MyRedis", - "database_type": "Pay as You Go", - "region": "eu-central-1", - "port": 30143, - "creation_time": 1658909671, - "state": "active", - "password": "49665a1710f3434d8be008aab50f38d2", - "user_email": "example@upstash.com", - "endpoint": "eu2-sought-mollusk-30143.upstash.io", - "tls": true, - "consistent": false, - "pool_id": "f886c7f3", - "rest_token": "AXW_ASQgOTZhZDA4NTYtMDNiMS00ZWU3LTk2NjYtZTgxYWJkMDM0OWUxNDk2NjVhMTcxMGYzNDM0ZDhiZTAwOGFhYjUwZjM4ZDI=", - "read_only_rest_token": "AnW_ASQgOTZhZDA4NTYtMDNiMS00ZWU3LTk2NjYtZTgxYWJkMDM0OWUxB5sRhCROkPsxozFcDzDgVGRAxUI7UUr0Y6uFB7jMIOI=" -} -``` - diff --git a/devops/developer-api/redis/update_budget.mdx b/devops/developer-api/redis/update_budget.mdx deleted file mode 100644 index 3fbeae39..00000000 --- a/devops/developer-api/redis/update_budget.mdx +++ /dev/null @@ -1,64 +0,0 @@ ---- -title: "Update Database Budget" -description: "This endpoint updates the monthly budget of a Redis database." -api: "PATCH https://api.upstash.com/v2/redis/update-budget/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the database whose budget will be updated. - - -## Request Parameters - - - The new monthly budget for the database. - - - - -```shell curl -curl -X PATCH \ - https://api.upstash.com/v2/redis/update-budget/:id \ - -u 'EMAIL:API_KEY' \ - -d '{"budget": 200}' -``` - -```python Python -import requests - -data = '{"budget": 200}' -response = requests.patch('https://api.upstash.com/v2/redis/update-budget/:id', data=data, auth=('EMAIL', 'API_KEY')) -print(response.content) -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "budget": 200 -}`) -req, err := http.NewRequest("PATCH", "https://api.upstash.com/v2/redis/update-budget/:id", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText) -``` - - - - -```json 200 OK -"OK" -``` - \ No newline at end of file diff --git a/devops/developer-api/redis/update_regions.mdx b/devops/developer-api/redis/update_regions.mdx deleted file mode 100644 index 6ed170c0..00000000 --- a/devops/developer-api/redis/update_regions.mdx +++ /dev/null @@ -1,67 +0,0 @@ ---- -title: "Update Regions (Global)" -description: "Update the regions of global database" -api: "POST https://api.upstash.com/v2/redis/update-regions/{id}" -authMethod: "basic" ---- - -## Request - - - The ID of your database - - - -Array of read regions of the database - -**Options:** `us-east-1`, `us-west-1`, `us-west-2`, `eu-west-1`, `eu-central-1`, -`ap-southeast-1`, `ap-southeast-2`, `sa-east-1` - - - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/redis/update-regions/:id \ - -u 'EMAIL:API_KEY' \ - -d '{ "read_regions":["us-west-1"] }' -``` - -```python Python -import requests - -data = '{"read_regions":["eu-west-1"]}' - -response = requests.post('https://api.upstash.com/v2/redis/database', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{, - "read_regions":["us-west-1"] -}`) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/redis/read-regions/:id", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -"OK" -``` - diff --git a/devops/developer-api/teams/add_team_member.mdx b/devops/developer-api/teams/add_team_member.mdx deleted file mode 100644 index db5e41c2..00000000 --- a/devops/developer-api/teams/add_team_member.mdx +++ /dev/null @@ -1,90 +0,0 @@ ---- -title: "Add Team Member" -description: "This endpoint adds a new team member to the specified team." -api: "POST https://api.upstash.com/v2/teams/member" -authMethod: "basic" ---- - -## Request Parameters - - - Id of the team to add the member to - - - - Email of the new team member - - - - Role of the new team member -
**Options:** `admin`, `dev` or `finance` -
- -## Response Parameters - - - ID of the created team - - - Name of the created team - - - Email of the new team member - - - Role of the new team member - - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/teams/member \ - -u 'EMAIL:API_KEY' \ - -d '{"team_id":"95849b27-40d0-4532-8695-d2028847f823","member_email":"example@upstash.com","member_role":"dev"}' -``` - -```python Python -import requests - -data = '{"team_id":"95849b27-40d0-4532-8695-d2028847f823","member_email":"example@upstash.com","member_role":"dev"}' - -response = requests.post('https://api.upstash.com/v2/teams/member', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "team_id":"95849b27-40d0-4532-8695-d2028847f823", - "member_email":"example@upstash.com", - "member_role":"dev" -}`) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/teams/member", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -{ - "team_id": "95849b27-40d0-4532-8695-d2028847f823", - "team_name": "test_team_name", - "member_email": "example@upstash.com", - "member_role": "dev" -} -``` - diff --git a/devops/developer-api/teams/create_team.mdx b/devops/developer-api/teams/create_team.mdx deleted file mode 100644 index bb921065..00000000 --- a/devops/developer-api/teams/create_team.mdx +++ /dev/null @@ -1,81 +0,0 @@ ---- -title: "Create Team" -description: "This endpoint creates a new team." -api: "POST https://api.upstash.com/v2/team" -authMethod: "basic" ---- - -## Request Parameters - - - Name of the new team - - - - Whether to copy existing credit card information to team or not\ Options: - `true` or `false` - - -## Response Parameters - - - ID of the created team - - - Name of the created team - - - Whether creditcard information added to team during creation or not - - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/team \ - -u 'EMAIL:API_KEY' \ - -d '{"team_name":"myteam","copy_cc":true}' -``` - -```python Python -import requests - -data = '{"team_name":"myteam","copy_cc":true}' - -response = requests.post('https://api.upstash.com/v2/team', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "team_name":"myteam", - "copy_cc":true -}`) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/team", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -{ - "team_id": "75b471f2-15a1-47b0-8ce5-12a57682bfc9", - "team_name": "test_team_name_2", - "copy_cc": true -} -``` - diff --git a/devops/developer-api/teams/delete_team.mdx b/devops/developer-api/teams/delete_team.mdx deleted file mode 100644 index 0d88250c..00000000 --- a/devops/developer-api/teams/delete_team.mdx +++ /dev/null @@ -1,57 +0,0 @@ ---- -title: "Delete Team" -description: "This endpoint deletes a team." -api: "DELETE https://api.upstash.com/v2/team/{id}" -authMethod: "basic" ---- - -## URL Parameters - - - The ID of the team to delete - - -## Response Parameters - -"OK" - - - -```shell curl -curl -X DELETE \ - https://api.upstash.com/v2/team/:id \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.delete('https://api.upstash.com/v2/team/:id' auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("DELETE", "https://api.upstash.com/v2/team/:id", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -"OK" -``` - diff --git a/devops/developer-api/teams/delete_team_member.mdx b/devops/developer-api/teams/delete_team_member.mdx deleted file mode 100644 index f50744aa..00000000 --- a/devops/developer-api/teams/delete_team_member.mdx +++ /dev/null @@ -1,68 +0,0 @@ ---- -title: "Delete Team Member" -description: "This endpoint deletes a team member from the specified team." -api: "DELETE https://api.upstash.com/v2/teams/member" -authMethod: "basic" ---- - -## Request Parameters - - - Id of the team to add the member to - - - - Email of the new team member - - -## Response Parameters - -"OK" - - - -```shell curl -curl -X DELETE \ - https://api.upstash.com/v2/teams/member \ - -u 'EMAIL:API_KEY' \ - -d '{"team_id":"95849b27-40d0-4532-8695-d2028847f823","member_email":"example@upstash.com"}' -``` - -```python Python -import requests - -data = '{"team_id":"95849b27-40d0-4532-8695-d2028847f823","member_email":"example@upstash.com"}' - -response = requests.delete('https://api.upstash.com/v2/teams/member', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "team_id":"95849b27-40d0-4532-8695-d2028847f823", - "member_email":"example@upstash.com" -}`) -req, err := http.NewRequest("DELETE", "https://api.upstash.com/v2/teams/member", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -"OK" -``` - diff --git a/devops/developer-api/teams/get_team_members.mdx b/devops/developer-api/teams/get_team_members.mdx deleted file mode 100644 index 7bc065f7..00000000 --- a/devops/developer-api/teams/get_team_members.mdx +++ /dev/null @@ -1,81 +0,0 @@ ---- -title: "Get Team Members" -description: "This endpoint list all members of a team." -api: "GET https://api.upstash.com/v2/teams/{team_id}" -authMethod: "basic" ---- - -## Request Parameters - - - ID of the team - - -## Response Parameters - - - ID of the team - - - Name of the team - - - Email of the team member - - - Role of the team member - - - - -```shell curl -curl -X GET \ - https://api.upstash.com/v2/teams/:id \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.get('https://api.upstash.com/v2/teams/:id', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("GET", "https://api.upstash.com/v2/teams/:id", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -[ - { - "team_id": "3423cb72-e50d-43ec-a9c0-f0f359941223", - "team_name": "test_team_name_2", - "member_email": "example@upstash.com", - "member_role": "dev" - }, - { - "team_id": "3423cb72-e50d-43ec-a9c0-f0f359941223", - "team_name": "test_team_name_2", - "member_email": "example_2@upstash.com", - "member_role": "owner" - } -] -``` - diff --git a/devops/developer-api/teams/list_teams.mdx b/devops/developer-api/teams/list_teams.mdx deleted file mode 100644 index 07f3b093..00000000 --- a/devops/developer-api/teams/list_teams.mdx +++ /dev/null @@ -1,69 +0,0 @@ ---- -title: "List Teams" -description: "This endpoint lists all teams of user." -api: "GET https://api.upstash.com/v2/teams" -authMethod: "basic" ---- - -## Response Parameters - - - ID of the created team - - - Role of the user in this team - - - Name of the created team - - - Whether creditcard information added to team during creation or not - - - - -```shell curl -url -X GET \ - https://api.upstash.com/v2/teams \ - -u 'EMAIL:API_KEY' -``` - -```python Python -import requests - -response = requests.get('https://api.upstash.com/v2/teams', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -req, err := http.NewRequest("GET", "https://api.upstash.com/v2/teams", nil) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -[ - { - "team_id": "95849b27-40d0-4532-8695-d2028847f823", - "team_name": "test_team_name", - "member_role": "owner", - "copy_cc": true - } -] -``` - diff --git a/devops/developer-api/vector/create_index.mdx b/devops/developer-api/vector/create_index.mdx deleted file mode 100644 index e22402b6..00000000 --- a/devops/developer-api/vector/create_index.mdx +++ /dev/null @@ -1,212 +0,0 @@ ---- -title: "Create Index" -description: "This endpoint creates an index." -api: "POST https://api.upstash.com/v2/vector/index" -authMethod: "basic" ---- - -## Request Parameters - - - Name of the index. - - - Region of the database.\ - **Options:** `eu-west-1`, `us-east-1`, - - - - Similarity function that's used to calculate the distance between two - vectors.\ - **Options:** `COSINE`, `EUCLIDIAN`, `DOT_PRODUCT` - - - - The amount of values in a single vector. - - - - The payment plan of your index.\ - **Options:** `payg`, `fixed` - - - - The payment plan of your index.\ - **Options:** `BGE_SMALL_EN_V1_5`, `BGE_BASE_EN_V1_5`, `BGE_LARGE_EN_V1_5`, `BGE_M3`, `BERT_BASE_UNCASED`, `UAE_Large_V1`, `ALL_MINILM_L6_V2`, `MXBAI_EMBED_LARGE_V1` - - -## Response Parameters - - - The associated ID of the owner of the index - - - Unique ID of the index - - - The name of the index. - - - Similarity function that's used to calculate the distance between two - vectors - - - The amount of values in a single vector - - - The REST endpoint of the index - - - The REST authentication token for the index - - - The REST authentication read only token for the index - - - The payment plan of the index - - - The region where the index is currently deployed. - - - The number of maximum that your index can contain. - - - The number of maximum update operations you can perform in a day. Only upsert operations are included in update count. - - - The number of maximum query operations you can perform in a day. Only query operations are included in query count. - - - The maximum amount of monthly bandwidth for the index. Unit is bytes. `-1` if the limit is unlimited. - - - The number of maximum write operations you can perform per second. Only upsert operations are included in write count. - - - The number of maximum query operations you can perform per second. Only query operations are included in query count. - - - The number of maximum vectors in a read operation. Query and fetch operations are included in read operations. - - - The number of maximum vectors in a write operation. Only upsert operations are included in write operations. - - - The amount of maximum size for the total metadata sizes in your index. - - - Monthly pricing of your index. Only available for fixed and pro plans. - - - The creation time of the vector index in UTC as unix timestamp. - - - The predefined embedding model to vectorize your plain text. - - - - - -```shell curl -curl -X POST https://api.upstash.com/v2/vector/index \ - -u 'EMAIL:API_KEY' \ - -d '{ - "name": "myindex", - "region": "eu-west-1", - "similarity_function": "COSINE", - "dimension_count": 1536 - }' \ -``` - -```javascript JavaScript -const axios = require('axios'); - -const postData = { - name: "myindex", - region: "eu-west-1", - similarity_function: "COSINE", - dimension_count: 1536, -}; - -const config = { - auth: { - username: 'EMAIL', - password: 'API_KEY', - }, - headers: { - 'Content-Type': 'application/json', - }, -}; - -axios.post('https://api.upstash.com/v2/vector/index', postData, config) - .then((response) => { - console.log('Response:', response.data); - }) - .catch((error) => { - console.error('Error:', error); - }); -``` - -```python Python -import requests - -data = '{"name":"myindex","region":"eu-west-1","similarity_function":"COSINE","dimension_count":1536}' - -response = requests.post('https://api.upstash.com/v2/vector/index', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader('{ - "name":"myindex", - "region":"eu-west-1", - "similarity_function":"COSINE", - "dimension_count":1536}' - ) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/vector/index", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -{ - "customer_id": "test@upstash.com", - "id": "0639864f-ece6-429c-8118-86a287b0e808", - "name": "myindex", - "similarity_function": "COSINE", - "dimension_count": 5, - "embedding_model": "BGE_SMALL_EN_V1_5" - "endpoint": "test-index-3814-eu1-vector.upstash.io", - "token": "QkZGMk5heGltdW0tdXBkYXRlZC0zNzM1LWV1MkFkbWlOeGZGZ1J5Wm1GdE5tTXhNQzB1TmpsbExUb3hOekF0TVRJbFpqMTJORFUxTm1GZw==", - "read_only_token": "QkZGRk1heGltdW0tdXBkYXRlZC0zNzM1LWV1MnJlYWRvbmx5TmtaZ05qS3JNWVV0Wm1aZ01pMDBOV1poTHRob05qY3RNR0U0TkRjejNqazJU" - "type": "paid", - "region": "eu-west-1", - "max_vector_count": 400000000, - "max_daily_updates": -1, - "max_daily_queries": -1, - "max_monthly_bandwidth": -1, - "max_writes_per_second": 1000, - "max_query_per_second": 1000, - "max_reads_per_request": 1000, - "max_writes_per_request": 1000, - "max_total_metadata_size": 53687091200, - "creation_time": 1707313165 -} -``` - \ No newline at end of file diff --git a/devops/developer-api/vector/delete_index.mdx b/devops/developer-api/vector/delete_index.mdx deleted file mode 100644 index 2428c3ec..00000000 --- a/devops/developer-api/vector/delete_index.mdx +++ /dev/null @@ -1,80 +0,0 @@ ---- -title: "Delete Index" -description: "This endpoint deletes an index." -api: "DELETE https://api.upstash.com/v2/vector/index/{id}" -authMethod: "basic" ---- - -## Request Parameters - - - The unique ID of the index to be deleted. - - -## Response Parameters - -`"OK"` on successfull deletion operation. - - - -```shell curl -curl -X DELETE https://api.upstash.com/v2/vector/index/0639864f-ece6-429c-8118-86a287b0e808 \ - -u 'EMAIL:API_KEY' -``` - -```javascript JavaScript -const axios = require('axios'); - -const config = { - auth: { - username: 'EMAIL', - password: 'API_KEY', - }, -}; - -const url = 'https://api.upstash.com/v2/vector/index/0639864f-ece6-429c-8118-86a287b0e808'; - -axios.delete(url, config) - .then((response) => { - console.log('Deleted successfully', response.data); - }) - .catch((error) => { - console.error('Error:', error); - }); -``` - -```python Python -import requests - -id="0639864f-ece6-429c-8118-86a287b0e808" - -response = requests.delete(f"https://api.upstash.com/v2/vector/index/{id}", auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} - -req, err := http.NewRequest("DELETE", "https://api.upstash.com/v2/vector/index/0639864f-ece6-429c-8118-86a287b0e808", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -"OK" -``` - diff --git a/devops/developer-api/vector/get_index.mdx b/devops/developer-api/vector/get_index.mdx deleted file mode 100644 index 9bca8284..00000000 --- a/devops/developer-api/vector/get_index.mdx +++ /dev/null @@ -1,166 +0,0 @@ ---- -title: "Get Index" -description: "This endpoint returns the data associated to a index." -api: "GET https://api.upstash.com/v2/vector/index/{id}" -authMethod: "basic" ---- - -## Request Parameters - - - The unique ID of the index to fetch. - - - -## Response Parameters - - - The associated ID of the owner of the index - - - Unique ID of the index - - - The name of the index. - - - Similarity function that's used to calculate the distance between two - vectors - - - The amount of values in a single vector - - - The REST endpoint of the index - - - The REST authentication token for the index - - - The REST authentication read only token for the index - - - The payment plan of the index - - - The region where the index is currently deployed. - - - The number of maximum that your index can contain. - - - The number of maximum update operations you can perform in a day. Only upsert operations are included in update count. - - - The number of maximum query operations you can perform in a day. Only query operations are included in query count. - - - The maximum amount of monthly bandwidth for the index. Unit is bytes. `-1` if the limit is unlimited. - - - The number of maximum write operations you can perform per second. Only upsert operations are included in write count. - - - The number of maximum query operations you can perform per second. Only query operations are included in query count. - - - The number of maximum vectors in a read operation. Query and fetch operations are included in read operations. - - - The number of maximum vectors in a write operation. Only upsert operations are included in write operations. - - - The amount of maximum size for the total metadata sizes in your index. - - - Monthly pricing of your index. Only available for fixed and pro plans. - - - The creation time of the vector index in UTC as unix timestamp. - - - - -```shell curl -curl -X GET https://api.upstash.com/v2/vector/index/0639864f-ece6-429c-8118-86a287b0e808 \ - -u 'EMAIL:API_KEY' \ -``` - -```javascript JavaScript -const axios = require('axios'); - -const config = { - auth: { - username: 'EMAIL', - password: 'API_KEY', - }, -}; - -const url = 'https://api.upstash.com/v2/vector/index/0639864f-ece6-429c-8118-86a287b0e808'; - -axios.get(url, config) - .then((response) => { - console.log(response.data); - }) - .catch((error) => { - console.error('Error:', error); - }); -``` - - -```python Python -import requests - -id = "0639864f-ece6-429c-8118-86a287b0e808" - -response = requests.post(f"https://api.upstash.com/v2/vector/index/{id}", auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} - -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/vector/index/0639864f-ece6-429c-8118-86a287b0e808", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -{ - "customer_id": "test@upstash.com", - "id": "0639864f-ece6-429c-8118-86a287b0e808", - "name": "myindex", - "similarity_function": "COSINE", - "dimension_count": 5, - "endpoint": "test-index-3814-eu1-vector.upstash.io", - "token": "QkZGMk5heGltdW0tdXBkYXRlZC0zNzM1LWV1MkFkbWlOeGZGZ1J5Wm1GdE5tTXhNQzB1TmpsbExUb3hOekF0TVRJbFpqMTJORFUxTm1GZw==", - "read_only_token": "QkZGRk1heGltdW0tdXBkYXRlZC0zNzM1LWV1MnJlYWRvbmx5TmtaZ05qS3JNWVV0Wm1aZ01pMDBOV1poTHRob05qY3RNR0U0TkRjejNqazJU" - "type": "paid", - "region": "eu-west-1", - "max_vector_count": 400000000, - "max_daily_updates": -1, - "max_daily_queries": -1, - "max_monthly_bandwidth": -1, - "max_writes_per_second": 1000, - "max_query_per_second": 1000, - "max_reads_per_request": 1000, - "max_writes_per_request": 1000, - "max_total_metadata_size": 53687091200, - "creation_time": 1707313165 -} -``` - diff --git a/devops/developer-api/vector/list_indices.mdx b/devops/developer-api/vector/list_indices.mdx deleted file mode 100644 index f6434bda..00000000 --- a/devops/developer-api/vector/list_indices.mdx +++ /dev/null @@ -1,162 +0,0 @@ ---- -title: "List Indices" -description: "This endpoint returns the data related to all indices of an account as a list." -api: "GET https://api.upstash.com/v2/vector/index/" -authMethod: "basic" ---- - -## Request Parameters - -This endpoint doesn't require any additional data. - -## Response Parameters - - - - - The associated ID of the owner of the index - - - Unique ID of the index - - - The name of the index. - - - Similarity function that's used to calculate the distance between two - vectors - - - The amount of values in a single vector - - - The REST endpoint of the index - - - The payment plan of the index - - - The region where the index is currently deployed. - - - The number of maximum that your index can contain. - - - The number of maximum update operations you can perform in a day. Only upsert operations are included in update count. - - - The number of maximum query operations you can perform in a day. Only query operations are included in query count. - - - The maximum amount of monthly bandwidth for the index. Unit is bytes. `-1` if the limit is unlimited. - - - The number of maximum write operations you can perform per second. Only upsert operations are included in write count. - - - The number of maximum query operations you can perform per second. Only query operations are included in query count. - - - The number of maximum vectors in a read operation. Query and fetch operations are included in read operations. - - - The number of maximum vectors in a write operation. Only upsert operations are included in write operations. - - - The amount of maximum size for the total metadata sizes in your index. - - - Monthly pricing of your index. Only available for fixed and pro plans. - - - The creation time of the vector index in UTC as unix timestamp. - - - - - - -```shell curl -curl -X GET \ - https://api.upstash.com/v2/vector/index \ - -u 'EMAIL:API_KEY' \ -``` - -```javascript JavaScript -const axios = require('axios'); - -const config = { - auth: { - username: 'EMAIL', - password: 'API_KEY', - }, -}; - -const url = 'https://api.upstash.com/v2/vector/index'; - -axios.get(url, config) - .then((response) => { - console.log(response.data); - }) - .catch((error) => { - console.error('Error:', error); - }); -``` - -```python Python -import requests - -response = requests.get('https://api.upstash.com/v2/vector/index', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} - -req, err := http.NewRequest("GET", "https://api.upstash.com/v2/vector/index") -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -[ - { - "customer_id": "test@upstash.com", - "id": "0639864f-ece6-429c-8118-86a287b0e808", - "name": "myindex", - "similarity_function": "COSINE", - "dimension_count": 5, - "endpoint": "test-index-3814-eu1-vector.upstash.io", - "token": "QkZGMk5heGltdW0tdXBkYXRlZC0zNzM1LWV1MkFkbWlOeGZGZ1J5Wm1GdE5tTXhNQzB1TmpsbExUb3hOekF0TVRJbFpqMTJORFUxTm1GZw==", - "read_only_token": "QkZGRk1heGltdW0tdXBkYXRlZC0zNzM1LWV1MnJlYWRvbmx5TmtaZ05qS3JNWVV0Wm1aZ01pMDBOV1poTHRob05qY3RNR0U0TkRjejNqazJU" - "type": "paid", - "region": "eu-west-1", - "max_vector_count": 400000000, - "max_daily_updates": -1, - "max_daily_queries": -1, - "max_monthly_bandwidth": -1, - "max_writes_per_second": 1000, - "max_query_per_second": 1000, - "max_reads_per_request": 1000, - "max_writes_per_request": 1000, - "max_total_metadata_size": 53687091200, - "creation_time": 1707313165 - } -] -``` - - diff --git a/devops/developer-api/vector/rename_index.mdx b/devops/developer-api/vector/rename_index.mdx deleted file mode 100644 index 8c933ebe..00000000 --- a/devops/developer-api/vector/rename_index.mdx +++ /dev/null @@ -1,96 +0,0 @@ ---- -title: "Rename Index" -description: "This endpoint is used to change the name of an index." -api: "POST https://api.upstash.com/v2/vector/index/{id}/rename" -authMethod: "basic" ---- - -## Request Parameters - - - The unique ID of the index to be deleted. - - - - The new name of the index. - - -## Response Parameters - -`"OK"` on successfull deletion operation. - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/rename \ - -u 'EMAIL:API_KEY' \ - -d '{"name":"myindex"}' -``` - -```javascript JavaScript -const axios = require('axios'); - -const postData = { - name: "myindex", -}; - -const config = { - auth: { - username: 'EMAIL', - password: 'API_KEY', - }, - headers: { - 'Content-Type': 'application/json', - }, -}; - -const url = 'https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/rename'; - -axios.post(url, postData, config) - .then((response) => { - console.log('Rename successful:', response.data); - }) - .catch((error) => { - console.error('Error:', error); - }); -``` - -```python Python -import requests - -data = '{"name":"myindex"}' - -response = requests.post('https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/rename', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "name":"myindex", -}`) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/rename", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -"OK" -``` - - diff --git a/devops/developer-api/vector/reset_index_passwords.mdx b/devops/developer-api/vector/reset_index_passwords.mdx deleted file mode 100644 index eb74b839..00000000 --- a/devops/developer-api/vector/reset_index_passwords.mdx +++ /dev/null @@ -1,85 +0,0 @@ ---- -title: "Reset Index Passwords" -description: "This endpoint is used to reset regular and readonly tokens of an index." -api: "POST https://api.upstash.com/v2/vector/index/{id}/reset-password" -authMethod: "basic" ---- - -## Request Parameters - - - The unique ID of the index to reset the password for.. - - -## Response Parameters - -`"OK"` on successfull deletion operation. - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/reset-password \ - -u 'EMAIL:API_KEY' \ -``` - -```javascript JavaScript -const axios = require('axios'); - -const config = { - auth: { - username: 'EMAIL', - password: 'API_KEY', - }, - headers: { - 'Content-Type': 'application/json', - }, -}; - -const url = 'https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/reset-password'; - -axios.post(url, {}, config) // Sending an empty object as data since no payload is required. - .then((response) => { - console.log('Operation successful:', response.data); - }) - .catch((error) => { - console.error('Error:', error); - }); - -``` - -```python Python -import requests - -response = requests.post('https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/reset-password', auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} - -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/reset-password") - -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -"OK" -``` - - diff --git a/devops/developer-api/vector/set_index_plan.mdx b/devops/developer-api/vector/set_index_plan.mdx deleted file mode 100644 index 659e52f9..00000000 --- a/devops/developer-api/vector/set_index_plan.mdx +++ /dev/null @@ -1,97 +0,0 @@ ---- -title: "Set Index Plan" -description: "This endpoint is used to change the plan of an index." -api: "POST https://api.upstash.com/v2/vector/index/{id}/setplan" -authMethod: "basic" ---- - -## Request Parameters - - - The unique ID of the index to be deleted. - - - - The new plan for the index. - - -## Response Parameters - -`"OK"` on successfull deletion operation. - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/setplan \ - -u 'EMAIL:API_KEY' \ - -d '{"target_plan":"fixed"}' -``` - -```javascript JavaScript -const axios = require('axios'); - -const postData = { - target_plan: "fixed", -}; - -const config = { - auth: { - username: 'EMAIL', - password: 'API_KEY', - }, - headers: { - 'Content-Type': 'application/json', - }, -}; - -const url = 'https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/setplan'; - -axios.post(url, postData, config) - .then((response) => { - console.log('Plan set successfully:', response.data); - }) - .catch((error) => { - console.error('Error:', error); - }); - -``` - -```python Python -import requests - -data = '{"target_plan":"fixed"}' - -response = requests.post('https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/setplan', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "target_plan":"fixed", -}`) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/setplan", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -"OK" -``` - - diff --git a/devops/developer-api/vector/transfer_index.mdx b/devops/developer-api/vector/transfer_index.mdx deleted file mode 100644 index 2c702bab..00000000 --- a/devops/developer-api/vector/transfer_index.mdx +++ /dev/null @@ -1,98 +0,0 @@ ---- -title: "Transfer Index" -description: "This endpoint is used to transfer an index to another team." -api: "POST https://api.upstash.com/v2/vector/index/{id}/transfer" -authMethod: "basic" ---- - - -## Request Parameters - - - The unique ID of the index to be deleted. - - - - The ID of the target account. If the target is a team, then use the format `team:`, else if the target is your personal account use the format ``. - - -## Response Parameters - -`"OK"` on successfull deletion operation. - - - -```shell curl -curl -X POST \ - https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/transfer \ - -u 'EMAIL:API_KEY' \ - -d '{"target_account":"team:team-id-1"}' -``` - -```javascript JavaScript -const axios = require('axios'); - -const postData = { - target_account: "team:team-id-1", -}; - -const config = { - auth: { - username: 'EMAIL', - password: 'API_KEY', - }, - headers: { - 'Content-Type': 'application/json', - }, -}; - -const url = 'https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/transfer'; - -axios.post(url, postData, config) - .then((response) => { - console.log('Transfer successful:', response.data); - }) - .catch((error) => { - console.error('Error:', error); - }); -``` - -```python Python -import requests - -data = '{"target_account":"team:team-id-1"}' - -response = requests.post('https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/transfer', data=data, auth=('EMAIL', 'API_KEY')) -response.content -``` - -```go Go -client := &http.Client{} -var data = strings.NewReader(`{ - "target_account":"team:team-id-1", -}`) -req, err := http.NewRequest("POST", "https://api.upstash.com/v2/vector/index/14841111-b834-4788-925c-04ab156d1123/transfer", data) -if err != nil { - log.Fatal(err) -} -req.SetBasicAuth("email", "api_key") -resp, err := client.Do(req) -if err != nil { - log.Fatal(err) -} -bodyText, err := ioutil.ReadAll(resp.Body) -if err != nil { - log.Fatal(err) -} -fmt.Printf("%s\n", bodyText); -``` - - - - -```json 200 OK -"OK" -``` - - - diff --git a/docs.json b/docs.json index 86866d22..daf1e405 100644 --- a/docs.json +++ b/docs.json @@ -1370,6 +1370,7 @@ }, { "tab": "Developer API", + "openapi": "devops/developer-api/openapi.yml", "groups": [ { "group": "Developer API", @@ -1380,32 +1381,31 @@ { "group": "Redis", "pages": [ - "devops/developer-api/redis/create_database", - "devops/developer-api/redis/create_database_global", - "devops/developer-api/redis/delete_database", - "devops/developer-api/redis/list_databases", - "devops/developer-api/redis/get_database", - "devops/developer-api/redis/get_database_stats", - "devops/developer-api/redis/update_regions", - "devops/developer-api/redis/reset_password", - "devops/developer-api/redis/rename_database", - "devops/developer-api/redis/enable_tls", - "devops/developer-api/redis/enable_eviction", - "devops/developer-api/redis/disable_eviction", - "devops/developer-api/redis/enable_autoscaling", - "devops/developer-api/redis/disable_autoscaling", - "devops/developer-api/redis/moveto_team", - "devops/developer-api/redis/change_plan", - "devops/developer-api/redis/update_budget", + "GET /redis/databases", + "GET /redis/database/{id}", + "GET /redis/stats/{id}", + "POST /redis/database", + "POST /redis/rename/{id}", + "POST /redis/reset-password/{id}", + "POST /redis/enable-tls/{id}", + "POST /redis/enable-eviction/{id}", + "POST /redis/disable-eviction/{id}", + "POST /redis/enable-autoupgrade/{id}", + "POST /redis/disable-autoupgrade/{id}", + "POST /redis/change-plan/{id}", + "POST /redis/update-regions/{id}", + "POST /redis/move-to-team", + "PATCH /redis/update-budget/{id}", + "DELETE /redis/database/{id}", { "group": "Backup", "pages": [ - "devops/developer-api/redis/backup/create_backup", - "devops/developer-api/redis/backup/delete_backup", - "devops/developer-api/redis/backup/restore_backup", - "devops/developer-api/redis/backup/list_backup", - "devops/developer-api/redis/backup/enable_dailybackup", - "devops/developer-api/redis/backup/disable_dailybackup" + "GET /redis/list-backup/{id}", + "POST /redis/create-backup/{id}", + "POST /redis/restore-backup/{id}", + "PATCH /redis/enable-dailybackup/{id}", + "PATCH /redis/disable-dailybackup/{id}", + "DELETE /redis/delete-backup/{id}/{backup_id}" ] } ] @@ -1413,25 +1413,25 @@ { "group": "Vector", "pages": [ - "devops/developer-api/vector/create_index", - "devops/developer-api/vector/delete_index", - "devops/developer-api/vector/list_indices", - "devops/developer-api/vector/get_index", - "devops/developer-api/vector/transfer_index", - "devops/developer-api/vector/rename_index", - "devops/developer-api/vector/reset_index_passwords", - "devops/developer-api/vector/set_index_plan" + "GET /vector/index", + "GET /vector/index/{id}", + "POST /vector/index", + "POST /vector/index/{id}/rename", + "POST /vector/index/{id}/reset-password", + "POST /vector/index/{id}/setplan", + "POST /vector/index/{id}/transfer", + "DELETE /vector/index/{id}" ] }, { "group": "Teams", "pages": [ - "devops/developer-api/teams/create_team", - "devops/developer-api/teams/delete_team", - "devops/developer-api/teams/list_teams", - "devops/developer-api/teams/add_team_member", - "devops/developer-api/teams/delete_team_member", - "devops/developer-api/teams/get_team_members" + "GET /teams", + "GET /teams/{team_id}", + "POST /team", + "POST /teams/member", + "DELETE /team/{id}", + "DELETE /teams/member" ] }, { From f61e039a7c3aaa8b97d66e73cabc9b89b634b7d3 Mon Sep 17 00:00:00 2001 From: alitariksahin Date: Thu, 4 Sep 2025 19:23:08 +0300 Subject: [PATCH 2/3] fix: get all the schemas up to date as much as possible --- devops/developer-api/openapi.yml | 459 +++++++++++++++++++++++-------- 1 file changed, 339 insertions(+), 120 deletions(-) diff --git a/devops/developer-api/openapi.yml b/devops/developer-api/openapi.yml index 2fccdfbd..141f075c 100644 --- a/devops/developer-api/openapi.yml +++ b/devops/developer-api/openapi.yml @@ -1009,6 +1009,7 @@ paths: type: string description: The new plan for the index enum: + - free - payg - fixed required: @@ -1075,74 +1076,52 @@ components: type: string description: Name of the database example: MyRedis - database_type: - type: string - description: Type of the database in terms of pricing model - example: Pay as You Go - enum: - - Free - - Pay as You Go - - Enterprise region: type: string description: The region where database is hosted - example: eu-central-1 + enum: ["global"] + example: global port: type: integer description: Database port for clients to connect format: int64 - example: 30143 + example: 6379 creation_time: type: integer description: Creation time of the database as Unix time format: int64 - example: 1658909671 + example: 1752649602 state: type: string description: State of database - example: active enum: - active - - deleted - password: - type: string - description: Password of the database - example: 038a8e27c45e43068d5f186085399884 - user_email: - type: string - description: Email or team id of the owner of the database - example: example@upstash.com + - suspended + - passive + example: active endpoint: type: string - description: Endpoint URL of the database - example: eu2-sought-mollusk-30143.upstash.io + description: Endpoint identifier or hostname of the database (may be a slug like "beloved-stallion-58500" or a full host) + example: beloved-stallion-58500 tls: type: boolean description: TLS/SSL is enabled or not example: true - rest_token: - type: string - description: Token for rest based communication with the database - example: AXW_ASQgOTZhZDA4NTYtMDNiMS00ZWU3LTk2NjYtZTgxYWJkMDM0OWUxMDM4YThlMjdjNDVlNDMwNjhkNWYxODYwODUzOTk4ODQ= - read_only_rest_token: - type: string - description: Read only token for rest based communication with the database - example: AnW_ASQgOTZhZDA4NTYtMDNiMS00ZWU3LTk2NjYtZTgxYWJkMDM0OWUx8sbmiEcMm9u7Ks5Qx-kHNiWr_f-iUXSIH8MlziKMnpY= db_max_clients: type: integer description: Max number of concurrent clients can be opened on this database currently format: int64 - example: 1000 + example: 10000 db_max_request_size: type: integer description: Max size of a request that will be accepted by the database currently(in bytes) format: int64 - example: 1048576 + example: 10485760 db_disk_threshold: type: integer description: Total disk size limit that can be used for the database currently(in bytes) format: int64 - example: 268435456 + example: 107374182400 db_max_entry_size: type: integer description: Max size of an entry that will be accepted by the database currently(in bytes) @@ -1152,110 +1131,180 @@ components: type: integer description: Max size of a memory the database can use(in bytes) format: int64 - example: 268435456 - db_daily_bandwidth_limit: - type: integer - description: Max daily bandwidth can be used by the database(in bytes) - format: int64 - example: 53687091200 + example: 3221225472 db_max_commands_per_second: type: integer description: Max number of commands can be sent to the database per second format: int64 - example: 1000 + example: 10000 db_request_limit: type: integer description: Total number of commands can be sent to the database format: int64 - example: 10000 - cluster_id: - type: string - description: Cluster ID of the database - pool_id: - type: string - description: Pool ID of the database + example: 8024278031528736858 type: type: string description: Payment plan of the database + enum: ["free", "payg", "pro", "paid"] example: paid budget: type: integer description: Allocated monthly budget for the database format: int64 + example: 360 primary_region: type: string description: Primary region of the database cluster + enum: + - ap-south-1 + - ap-southeast-1 + - ap-southeast-2 + - ap-northeast-1 + - eu-west-1 + - eu-west-2 + - eu-central-1 + - us-east-1 + - us-west-1 + - us-west-2 + - us-east-2 + - sa-east-1 + - ca-central-1 + example: us-east-1 primary_members: type: array items: type: string description: List of primary regions in the database cluster + example: ["us-east-1"] all_members: type: array items: type: string description: List of all regions in the database cluster + example: ["us-east-1"] eviction: type: boolean description: Entry eviction is enabled + example: false auto_upgrade: type: boolean description: Automatic upgrade capability is enabled + example: false consistent: type: boolean description: Strong consistency mode is enabled - reserved_per_region_price: - type: integer - description: Reserved price per region for enterprise plans - format: int64 - next_daily_backup_time: - type: integer - description: Unix timestamp of next scheduled backup - format: int64 + example: false modifying_state: type: string description: Current modifying state of the database + example: "" db_resource_size: type: string description: Resource allocation tier + enum: ["S", "M", "L", "XL", "XXL", "3XL"] + example: L db_type: type: string description: Database storage engine type + enum: ["bolt", "badger", "pebble"] + example: pebble db_conn_idle_timeout: type: integer description: Connection idle timeout in nanoseconds format: int64 + example: 21600000000000 db_lua_timeout: type: integer description: Lua script execution timeout in nanoseconds format: int64 + example: 250000000 db_lua_credits_per_min: type: integer description: Lua script execution credits per minute format: int64 + example: 10000000000 db_store_max_idle: type: integer description: Store connection idle timeout in nanoseconds format: int64 + example: 900000000000 db_max_loads_per_sec: type: integer description: Maximum load operations per second format: int64 + example: 1000000 db_acl_enabled: - type: boolean - description: Access Control List is enabled + type: string + description: Access Control List enabled status + enum: ["true", "false"] + example: "false" db_acl_default_user_status: - type: boolean + type: string description: Default user access status in ACL + enum: ["true", "false"] + example: "true" db_eviction: type: boolean description: Database-level eviction policy status + example: false + last_plan_upgrade_time: + type: integer + format: int64 + description: Unix timestamp of the last plan upgrade + example: 0 + replicas: + type: integer + description: Replica factor of the database + example: 5 + customer_id: + type: string + description: Owner identifier of the database (may be email or marketplace-scoped email) + example: "example@upstash.com" + daily_backup_enabled: + type: boolean + description: Whether daily backup is enabled + example: false + read_regions: + type: array + items: + type: string + description: Array of read regions of the database + example: ["us-east-2"] + securityAddons: + type: object + description: Security add-ons and their enablement status + properties: + ipWhitelisting: + type: boolean + vpcPeering: + type: boolean + privateLink: + type: boolean + tlsMutualAuth: + type: boolean + encryptionAtRest: + type: boolean + example: + ipWhitelisting: false + vpcPeering: false + privateLink: false + tlsMutualAuth: false + encryptionAtRest: false + prometheus_enabled: + type: string + description: Prometheus integration enabled status + enum: ["true", "false"] + example: "false" + prod_pack_enabled: + type: boolean + description: Production pack enabled status + example: false xml: name: database CreateDatabaseRequest: type: object properties: - name: + database_name: type: string description: Name of the database example: "myredis" @@ -1271,13 +1320,19 @@ components: description: Primary Region of the Global Database enum: - us-east-1 + - us-east-2 - us-west-1 - us-west-2 - - eu-west-1 + - ca-central-1 - eu-central-1 - - ap-southeast-1 - - ap-southeast-2 + - eu-west-1 + - eu-west-2 - sa-east-1 + - ap-south-1 + - ap-northeast-1 + - ap-southeast-1 + - us-central-1 + - us-east4 example: "us-east-1" read_regions: type: array @@ -1285,14 +1340,18 @@ components: type: string enum: - us-east-1 + - us-east-2 - us-west-1 - us-west-2 - - eu-west-1 + - ca-central-1 - eu-central-1 + - eu-west-1 + - eu-west-2 + - sa-east-1 + - ap-south-1 + - ap-northeast-1 - ap-southeast-1 - ap-southeast-2 - - ap-northeast-1 - - sa-east-1 description: Array of Read Regions of the Database example: ["us-west-1", "us-west-2"] plan: @@ -1301,6 +1360,7 @@ components: Specifies the fixed plan type for the database. If omitted, the database defaults to either the pay-as-you-go or free plan, based on the account type. enum: + - free - payg - fixed_250mb - fixed_1gb @@ -1313,19 +1373,32 @@ components: budget: type: integer description: Monthly budget of the database - example: 100 + example: 360 + eviction: + type: boolean + description: Whether to enable eviction for the database + example: false + tls: + type: boolean + description: Whether to enable TLS for the database + example: true required: - - name + - database_name - region - primary_region ChangePlanRequest: type: object properties: + database_id: + type: string + description: ID of the database + example: "6gcefvfd-9627-2tz5-4l71-c5679g19d2g4" plan_name: type: string description: The new plan for the database enum: + - free - payg - fixed_250mb - fixed_1gb @@ -1348,118 +1421,159 @@ components: DatabaseStats: type: object properties: + monitor_count: + $ref: "#/components/schemas/TimeSeriesData" + description: Monitor count + daily_net_commands: + type: integer + description: Total number of commands executed today + example: 7 + daily_read_requests: + type: integer + description: Total number of read requests executed today + example: 7 + daily_write_requests: + type: integer + description: Total number of write requests executed today + example: 0 connection_count: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: Connection count over time + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] keyspace: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: Total number of keys in the database over time + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] throughput: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: Throughput on database connections over time + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] produce_throughput: type: array nullable: true items: $ref: "#/components/schemas/TimeSeriesData" description: Write throughput over time + example: null consume_throughput: type: array nullable: true items: $ref: "#/components/schemas/TimeSeriesData" description: Read throughput over time + example: null diskusage: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: Disk usage over time - latencymax: + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] + latencymean: type: array items: $ref: "#/components/schemas/TimeSeriesData" - description: Maximum latency over time - latencymin: + description: Average latency over time + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] + latency_99: type: array items: $ref: "#/components/schemas/TimeSeriesData" - description: Minimum latency over time + description: 99th percentile latency over time + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] read_latency_mean: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: Average read latency over time + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] read_latency_99: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: 99th percentile read latency over time - latencymean: - type: array - items: - $ref: "#/components/schemas/TimeSeriesData" - description: Average latency over time + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] write_latency_mean: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: Average write latency over time + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] write_latency_99: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: 99th percentile write latency over time + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] hits: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: Cache hits over time + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] misses: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: Cache misses over time + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] read: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: Read requests over time + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] write: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: Write requests over time + example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] dailyrequests: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: Daily requests over time - dailybandwidth: - type: integer - description: Total daily bandwidth usage in bytes - example: 50444740913 - bandwidths: - type: array - items: - $ref: "#/components/schemas/TimeSeriesData" - description: Bandwidth usage over time + example: + [ + { "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }, + { "x": "2025-09-04 15:12:52.76649148 +0000 UTC", "y": 7 }, + ] days: type: array items: type: string description: Days of the week for measurement - example: ["Thursday", "Friday", "Saturday", "Sunday", "Monday"] + example: ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday"] dailybilling: type: array items: $ref: "#/components/schemas/TimeSeriesData" description: Daily billing amounts over time + example: + [ + { "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }, + { "x": "2025-09-04 15:12:52.76649148 +0000 UTC", "y": 1.333 }, + ] + dailybandwidth: + type: integer + description: Total daily bandwidth usage in bytes + example: 50444740913 + bandwidths: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Bandwidth usage over time + example: + [ + { "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }, + { "x": "2025-09-04 15:12:52.76649148 +0000 UTC", "y": 7 }, + ] dailyproduce: type: integer nullable: true @@ -1470,22 +1584,38 @@ components: nullable: true description: Total number of daily consumed commands example: 0 + total_monthly_bandwidth: + type: integer + description: Total bandwidth used in current month (bytes) + example: 7 total_monthly_requests: type: integer description: Total requests in current month - example: 1283856937 + example: 7 total_monthly_read_requests: type: integer description: Total read requests in current month - example: 1034567002 + example: 7 total_monthly_write_requests: type: integer description: Total write requests in current month - example: 249289935 + example: 0 + total_monthly_script_requests: + type: integer + description: Total script requests in current month + example: 0 + queue_optimized: + type: boolean + description: Whether queue optimization is enabled for the database + example: false total_monthly_storage: type: integer description: Total storage used in current month (bytes) - example: 445942383672 + example: 0 + current_storage: + type: integer + description: Current storage used (bytes) + example: 0 total_monthly_billing: type: number format: float @@ -1493,12 +1623,39 @@ components: example: 222.33902763855485 total_monthly_produce: type: integer + nullable: true description: Total produce commands in current month example: 0 total_monthly_consume: type: integer + nullable: true description: Total consume commands in current month example: 0 + command_counts: + type: array + description: Command-specific counts over time + items: + $ref: "#/components/schemas/CommandCount" + example: + [ + { + "metric_identifier": "EXISTS", + "data_points": + [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }], + }, + ] + CommandCount: + type: object + properties: + metric_identifier: + type: string + description: Command name or metric identifier + example: "EXISTS" + data_points: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Data points for the given command TimeSeriesData: type: object properties: @@ -1519,41 +1676,55 @@ components: database_id: type: string description: ID of the database - example: "6gceaafd-9627-4fa5-8g71-b3359g19a5g4" + example: "6gcqwafd-9627-4ec2-4g51-b1429h59c8d4" customer_id: type: string description: Customer ID - example: "customer_id" + example: "example@upstash.com" name: type: string description: Name of the backup - example: "test2" + example: "test" backup_id: type: string description: ID of the backup - example: "1768e55b-c137-4339-b46e-449dcd33a62e" + example: "1d62p45b-c567-1239-b23e-449ads33a62e" creation_time: type: integer description: Creation time of the backup as Unix time format: int64 - example: 1720186545 + example: 1757000716 state: type: string description: State of the backup - example: "completed" + enum: + - pending + - completed + - failed + example: "pending" backup_size: type: integer description: Size of the backup format: int64 example: 0 daily_backup: - type: boolean + type: string description: Daily backup status - example: false + enum: + - "true" + - "false" + example: "false" hourly_backup: - type: boolean + type: string description: Hourly backup status - example: false + enum: + - "true" + - "false" + example: "false" + internal_backup_tag: + type: string + description: Internal backup tag + example: "" xml: name: backup Team: @@ -1597,6 +1768,10 @@ components: - dev - finance example: "dev" + copy_cc: + type: boolean + description: Whether to copy existing credit card information to team member or not + example: true xml: name: teamMember CreateTeamRequest: @@ -1656,7 +1831,7 @@ components: customer_id: type: string description: The associated ID of the owner of the index - example: "test@upstash.com" + example: "example@upstash.com" id: type: string description: Unique ID of the index @@ -1670,13 +1845,13 @@ components: description: Similarity function that's used to calculate the distance between two vectors enum: - COSINE - - EUCLIDIAN + - EUCLIDEAN - DOT_PRODUCT example: "COSINE" dimension_count: type: number description: The amount of values in a single vector - example: 5 + example: 384 embedding_model: type: string description: The predefined embedding model to vectorize your plain text @@ -1686,49 +1861,58 @@ components: - BGE_LARGE_EN_V1_5 - BGE_M3 - BERT_BASE_UNCASED - - UAE_Large_V1 + - UAE_LARGE_V1 - ALL_MINILM_L6_V2 - MXBAI_EMBED_LARGE_V1 + - BM25 example: "BGE_SMALL_EN_V1_5" + sparse_embedding_model: + type: string + description: The sparse embedding model to be used for indexes + enum: + - BM25 + - BGE_M3 + example: "BM25" endpoint: type: string description: The REST endpoint of the index - example: "test-index-3814-eu1-vector.upstash.io" + example: "glowing-baboon-15797-us1" token: type: string description: The REST authentication token for the index - example: "QkZGMk5heGltdW0tdXBkYXRlZC0zNzM1LWV1MkFkbWlOeGZGZ1J5Wm1GdE5tTXhNQzB1TmpsbExUb3hOekF0TVRJbFpqMTJORFUxTm1GZw==" + example: "QkZGAsWp2tdW0tdC0zNzM1LWV1MkFkNQzB1ExUb3hOekF0TVRJbFpMDNLVSm1GZw==" read_only_token: type: string description: The REST authentication read only token for the index - example: "QkZGRk1heGltdW0tdXBkYXRlZC0zNzM1LWV1MnJlYWRvbmx5TmtaZ05qS3JNWVV0Wm1aZ01pMDBOV1poTHRob05qY3RNR0U0TkRjejNqazJU" + example: "QkZGRk1heGSKC0MtdRlZC0zNzM1LWTj3pAV0Wm1aZ01p05qY3RNR0U0TkRtRt2s9azJU" type: type: string description: The payment plan of the index enum: + - free - payg - fixed - - paid - example: "paid" + example: "fixed" region: type: string description: The region where the index is currently deployed enum: - eu-west-1 - us-east-1 - example: "eu-west-1" + - us-central-1 + example: "us-east-1" max_vector_count: type: number description: The number of maximum that your index can contain - example: 400000000 + example: 5210000 max_daily_updates: type: number description: The number of maximum update operations you can perform in a day. Only upsert operations are included in update count. - example: -1 + example: 1000000 max_daily_queries: type: number description: The number of maximum query operations you can perform in a day. Only query operations are included in query count. - example: -1 + example: 1000000 max_monthly_bandwidth: type: number description: The maximum amount of monthly bandwidth for the index. Unit is bytes. -1 if the limit is unlimited. @@ -1756,11 +1940,29 @@ components: reserved_price: type: number description: Monthly pricing of your index. Only available for fixed and pro plans. - example: 25.99 + example: 60 creation_time: type: number description: The creation time of the vector index in UTC as unix timestamp. - example: 1707313165 + example: 1753207106 + index_type: + type: string + description: The type of the vector index + enum: + - DENSE + - SPARSE + - HYBRID + example: "DENSE" + throughput_vector: + type: array + items: + $ref: "#/components/schemas/TimeSeriesData" + description: Throughput data for the vector index over time + example: + [ + { "x": "2025-09-04 14:55:00.000 +0000 UTC", "y": 0 }, + { "x": "2025-09-04 14:56:00.000 +0000 UTC", "y": 0 }, + ] xml: name: vectorIndex CreateIndexRequest: @@ -1776,19 +1978,20 @@ components: enum: - eu-west-1 - us-east-1 + - us-central-1 example: "us-east-1" similarity_function: type: string description: Similarity function that's used to calculate the distance between two vectors enum: - COSINE - - EUCLIDIAN + - EUCLIDEAN - DOT_PRODUCT example: "COSINE" dimension_count: type: number description: The amount of values in a single vector - example: 1536 + example: 1024 type: type: string description: The payment plan of your index @@ -1806,10 +2009,26 @@ components: - BGE_LARGE_EN_V1_5 - BGE_M3 - BERT_BASE_UNCASED - - UAE_Large_V1 + - UAE_LARGE_V1 - ALL_MINILM_L6_V2 - MXBAI_EMBED_LARGE_V1 - example: "BGE_SMALL_EN_V1_5" + - BM25 + example: "BGE_M3" + index_type: + type: string + description: The type of the vector index + enum: + - DENSE + - SPARSE + - HYBRID + example: "HYBRID" + sparse_embedding_model: + type: string + description: The sparse embedding model to be used for indexes + enum: + - BM25 + - BGE_M3 + example: "BM25" required: - name - region From 6a329ca7ca9367540221bca482b1404f6e8d6f7a Mon Sep 17 00:00:00 2001 From: alitariksahin Date: Thu, 4 Sep 2025 19:26:46 +0300 Subject: [PATCH 3/3] fix: remove nullable fields --- devops/developer-api/openapi.yml | 34 -------------------------------- 1 file changed, 34 deletions(-) diff --git a/devops/developer-api/openapi.yml b/devops/developer-api/openapi.yml index 141f075c..bd5a224b 100644 --- a/devops/developer-api/openapi.yml +++ b/devops/developer-api/openapi.yml @@ -1454,20 +1454,6 @@ components: $ref: "#/components/schemas/TimeSeriesData" description: Throughput on database connections over time example: [{ "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }] - produce_throughput: - type: array - nullable: true - items: - $ref: "#/components/schemas/TimeSeriesData" - description: Write throughput over time - example: null - consume_throughput: - type: array - nullable: true - items: - $ref: "#/components/schemas/TimeSeriesData" - description: Read throughput over time - example: null diskusage: type: array items: @@ -1574,16 +1560,6 @@ components: { "x": "2025-08-31 15:12:52.799480932 +0000 UTC", "y": 0 }, { "x": "2025-09-04 15:12:52.76649148 +0000 UTC", "y": 7 }, ] - dailyproduce: - type: integer - nullable: true - description: Total number of daily produced commands - example: 0 - dailyconsume: - type: integer - nullable: true - description: Total number of daily consumed commands - example: 0 total_monthly_bandwidth: type: integer description: Total bandwidth used in current month (bytes) @@ -1621,16 +1597,6 @@ components: format: float description: Total cost in current month example: 222.33902763855485 - total_monthly_produce: - type: integer - nullable: true - description: Total produce commands in current month - example: 0 - total_monthly_consume: - type: integer - nullable: true - description: Total consume commands in current month - example: 0 command_counts: type: array description: Command-specific counts over time