Set of 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format.Keys are strings with a maximum length of 64 characters. Values can be strings (max 512 characters), booleans, or numbers.
DELETE https://api.openai.com/v1/vector_stores/{vector_store_id}/files/{file_id}Delete a vector store file. This will remove the file from the vector store but the file itself will not be deleted. To delete the file, use the delete file endpoint.
from openai import OpenAIclient = OpenAI()# Add file to vector storevector_store_file = client.beta.vector_stores.files.create( vector_store_id="vs_abc123", file_id="file-abc123")print(vector_store_file.id, vector_store_file.status)# List files in vector storefiles = client.beta.vector_stores.files.list( vector_store_id="vs_abc123")for file in files: print(file.id, file.status)# Upload and attach file in one stepvector_store_file = client.beta.vector_stores.files.upload( vector_store_id="vs_abc123", file=open("mydata.pdf", "rb"))