{"id":25433372,"url":"https://github.com/box-community/box-curl-samples","last_synced_at":"2025-10-31T22:30:32.131Z","repository":{"id":51162673,"uuid":"200869183","full_name":"box-community/box-curl-samples","owner":"box-community","description":"A collection of cURL samples for the Box API. ","archived":false,"fork":false,"pushed_at":"2025-01-13T18:04:20.000Z","size":185,"stargazers_count":17,"open_issues_count":1,"forks_count":3,"subscribers_count":7,"default_branch":"main","last_synced_at":"2025-01-13T19:21:52.009Z","etag":null,"topics":["api","box","curl","platform","sample"],"latest_commit_sha":null,"homepage":"https://box.dev","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/box-community.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-08-06T14:35:47.000Z","updated_at":"2025-01-13T18:04:25.000Z","dependencies_parsed_at":"2024-06-06T13:03:27.386Z","dependency_job_id":"b91f8fdc-2abd-4f85-877b-8ff6cceba17a","html_url":"https://github.com/box-community/box-curl-samples","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/box-community%2Fbox-curl-samples","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/box-community%2Fbox-curl-samples/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/box-community%2Fbox-curl-samples/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/box-community%2Fbox-curl-samples/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/box-community","download_url":"https://codeload.github.com/box-community/box-curl-samples/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239236824,"owners_count":19604962,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api","box","curl","platform","sample"],"created_at":"2025-02-17T05:19:30.127Z","updated_at":"2025-02-17T05:19:30.748Z","avatar_url":"https://github.com/box-community.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cimg src=\"images/box-dev-logo-clip.png\"\nalt= “box-dev-logo”\nstyle=\"margin-left:-10px;\"\nwidth=40%;\u003e\n\n# Box cURL samples\n\n## Authorize a user\n\nAuthorize a user by sending them through the [Box](https://box.com)\nwebsite and request their permission to act on their behalf.\n\nThis is the first step when authenticating a user using\nOAuth 2.0. To request a user's authorization to use the Box APIs\non their behalf you will need to send a user to the URL with this\nformat.\n\n\u003c!-- sample get_authorize --\u003e\n\n```bash\ncurl -i -X GET \"https://account.box.com/api/oauth2/authorize?response_type=code\u0026client_id=ly1nj6n11vionaie65emwzk575hnnmrk\u0026redirect_uri=http://example.com/auth/callback\"\n```\n\n## Request an access token\n\nRequest an Access Token using either a client-side obtained OAuth2\nauthorization code or a server-side JWT assertion.\n\nAn Access Token is a string that enables Box to verify that a\nrequest belongs to an authorized session. In the normal order of\noperations you will begin by requesting authentication from the\n[authorize](#get-authorize) endpoint and Box will send you an\nauthorization code.\n\nYou will then send this code to this endpoint to exchange it for\nan Access Token. The returned Access Token can then be used to to make\nBox API calls.\n\n\u003c!-- sample post_oauth2_token --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/oauth2/token\" \\\n     -H \"content-type: application/x-www-form-urlencoded\" \\\n     -d \"client_id=[CLIENT_ID]\" \\\n     -d \"client_secret=[CLIENT_SECRET]\" \\\n     -d \"code=[CODE]\" \\\n     -d \"grant_type=authorization_code\"\n```\n\n## Refresh an access token\n\n\u003c!-- sample post_oauth2_token refresh --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/oauth2/token\" \\\n     -H \"content-type: application/x-www-form-urlencoded\" \\\n     -d \"client_id=[CLIENT_ID]\" \\\n     -d \"client_secret=[CLIENT_SECRET]\" \\\n     -d \"refresh_token=[REFRESH_TOKEN]\" \\\n     -d \"grant_type=refresh_token\"\n```\n\n## Downscope a token\n\n\u003c!-- sample post_oauth2_token downscope_token --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/oauth2/token\" \\\n     -H \"content-type: application/x-www-form-urlencoded\" \\\n     -d \"subject_token=[ACCESS_TOKEN]\" \\\n     -d \"subject_token_type=urn:ietf:params:oauth:token-type:access_token\" \\\n     -d \"scope=item_upload item_preview base_explorer\" \\\n     -d \"resource=https://api.box.com/2.0/folders/123456\" \\\n     -d \"grant_type=urn:ietf:params:oauth:grant-type:token-exchange\"\n```\n\n## Revoke an access token\n\nRevoke an active Access Token, effectively logging a user out\nthat has been previously authenticated.\n\n\u003c!-- sample post_oauth2_revoke --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/oauth2/revoke\" \\\n     -H \"content-type: application/x-www-form-urlencoded\" \\\n     -d \"client_id=[CLIENT_ID]\" \\\n     -d \"client_secret=[CLIENT_SECRET]\" \\\n     -d \"token=[ACCESS_TOKEN]\"\n```\n\n## Authentication with Client Credentials\n\nCreates a token using Client Credentials Grant, which\nallows you to log in as a Service Account.\n\n\u003c!-- sample x_auth with_client_credentials--\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/oauth2/token\" \\\n     -H \"content-type: application/x-www-form-urlencoded\" \\\n     -d \"client_id=[CLIENT_ID]\" \\\n     -d \"client_secret=[CLIENT_SECRET]\" \\\n     -d \"grant_type=client_credentials\" \\\n     -d \"box_subject_type=enterprise\"  \\\n     -d \"box_subject_id=[ENTERPRISE_ID]\"\n```\n\n## Authentication with CCG as an admin or managed user\n\nCreates a token using Client Credentials Grant, which\nallows you to log in as an admin or a managed user.\n\n\u003c!-- sample x_auth with_ccg_admin_managed_user--\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/oauth2/token\" \\\n     -H \"content-type: application/x-www-form-urlencoded\" \\\n     -d \"client_id=[CLIENT_ID]\" \\\n     -d \"client_secret=[CLIENT_SECRET]\" \\\n     -d \"grant_type=client_credentials\" \\\n     -d \"box_subject_type=user\"  \\\n     -d \"box_subject_id=[USER_ID]\"\n```\n\n## Authentication with CCG as app user\n\nCreates a token using Client Credentials Grant, which\nallows you to log in as any app user.\n\n\u003c!-- sample x_auth with_ccg_app_user--\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/oauth2/token\" \\\n     -H \"content-type: application/x-www-form-urlencoded\" \\\n     -d \"client_id=[CLIENT_ID]\" \\\n     -d \"client_secret=[CLIENT_SECRET]\" \\\n     -d \"grant_type=client_credentials\" \\\n     -d \"box_subject_type=user\"  \\\n     -d \"box_subject_id=[APPUSER_ID]\"\n```\n\n## Send request to AI\n\n\u003c!-- sample post_ai_ask--\u003e\n\n```bash\ncurl -i -L POST \"https://api.box.com/2.0/ai/ask\" \\\n     -H \"content-type: application/json\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -d '{\n         \"mode\": \"single_item_qa\",\n         \"prompt\": \"What is the value provided by public APIs based on this document?\",\n         \"items\": [\n            {\n            \"type\": \"file\",\n            \"id\": \"9842787262\"\n            }\n         ],\n         \"dialogue_history\": [\n              {\n              \"prompt\": \"Make my email about public APIs sound more professional\",\n              \"answer\": \"Here is the first draft of your professional email about public APIs\",\n              \"created_at\": \"2013-12-12T10:53:43-08:00\"\n              }\n          ],\n          \"include_citations\": true,\n          \"ai_agent\": {\n            \"type\": \"ai_agent_ask\",\n            \"long_text\": {\n              \"model\": \"azure__openai__gpt_4o_mini\",\n              \"prompt_template\": \"It is `{current_date}`, and I have $8000 and want to spend a week in the Azores. What should I see?\",\n            },\n            \"basic_text\": {\n              \"model\": \"azure__openai__gpt_4o_mini\",\n           }\n         }\n      }'\n```\n\n## Send request to AI (extended)\n\n\u003c!-- sample post_ai_ask_extended--\u003e\n\n```bash\ncurl -i -L POST \"https://api.box.com/2.0/ai/ask\" \\\n     -H \"content-type: application/json\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -d '{\n         \"mode\": \"single_item_qa\",\n         \"prompt\": \"What is the value provided by public APIs based on this document?\",\n         \"items\": [\n        {\n            \"type\": \"file\",\n            \"id\": \"9842787262\"\n        }\n       ],\n       \"dialogue_history\": [\n        {\n            \"prompt\": \"Make my email about public APIs sound more professional\",\n            \"answer\": \"Here is the first draft of your professional email about public APIs\",\n            \"created_at\": \"2013-12-12T10:53:43-08:00\"\n        }\n      ],\n       \"include_citations\": true,\n          \"ai_agent\": {\n            \"type\": \"ai_agent_ask\",\n            \"long_text\": {\n              \"model\": \"azure__openai__gpt_4o_mini\",\n              \"system_message\": \"You are a helpful travel assistant specialized in budget travel\",\n              \"prompt_template\": \"It is `{current_date}`, and I have $8000 and want to spend a week in the Azores. What should I see?\",\n              \"num_tokens_for_completion\": 8400,\n              \"llm_endpoint_params\": {\n                \"type\": \"openai_params\",\n                \"temperature\": 0.0,\n                \"top_p\": 1.0,\n                \"frequency_penalty\": 1.5,\n                \"presence_penalty\": 1.5,\n                \"stop\": \"\u003c|im_end|\u003e\"\n              },\n              \"embeddings\": {\n                \"model\": \"openai__text_embedding_ada_002\",\n                \"strategy\": {\n                  \"id\": \"basic\",\n                  \"num_tokens_per_chunk\": 8400\n                }\n              }\n            },\n            \"basic_text\": {\n              \"model\": \"azure__openai__gpt_4o_mini\",\n              \"system_message\": \"You are a helpful travel assistant specialized in budget travel\",\n              \"prompt_template\": \"It is `{current_date}`, and I have $8000 and want to spend a week in the Azores. What should I see?\",\n              \"num_tokens_for_completion\": 8400,\n              \"llm_endpoint_params\": {\n                \"type\": \"openai_params\",\n                \"temperature\": 0.0,\n                \"top_p\": 1.0,\n                \"frequency_penalty\": 1.5,\n                \"presence_penalty\": 1.5,\n                \"stop\": \"\u003c|im_end|\u003e\"\n              }\n            },\n              \"long_text_multi\": {\n                \"model\": \"azure__openai__gpt_4o_mini\",\n                \"system_message\": \"You are a helpful travel assistant specialized in budget travel\",\n                \"prompt_template\": \"It is `{current_date}`, and I have $8000 and want to spend a week in the Azores. What should I see?\",\n                \"num_tokens_for_completion\": 8400,\n                \"llm_endpoint_params\": {\n                  \"type\": \"openai_params\",\n                  \"temperature\": 0.0,\n                  \"top_p\": 1.0,\n                  \"frequency_penalty\": 1.5,\n                  \"presence_penalty\": 1.5,\n                  \"stop\": \"\u003c|im_end|\u003e\"\n                },\n                \"embeddings\": {\n                  \"model\": \"openai__text_embedding_ada_002\",\n                  \"strategy\": {\n                    \"id\": \"basic\",\n                    \"num_tokens_per_chunk\": 8400\n                  }\n                }\n              },\n              \"basic_text_multi\": {\n                \"model\": \"azure__openai__gpt_4o_mini\",\n                \"system_message\": \"You are a helpful travel assistant specialized in budget travel\",\n                \"prompt_template\": \"It is `{current_date}`, and I have $8000 and want to spend a week in the Azores. What should I see?\",\n                \"num_tokens_for_completion\": 8400,\n                  \"llm_endpoint_params\": {\n                    \"type\": \"openai_params\",\n                    \"temperature\": 0.0,\n                    \"top_p\": 1.0,\n                    \"frequency_penalty\": 1.5,\n                    \"presence_penalty\": 1.5,\n                    \"stop\": \"\u003c|im_end|\u003e\"\n              }\n          }\n      }'\n```\n\n## Send text generation request to AI\n\n\u003c!-- sample post_ai_text_gen--\u003e\n\n```bash\ncurl -i -L POST \"https://api.box.com/2.0/ai/text_gen\" \\\n     -H \"content-type: application/json\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -d '{\n          \"prompt\": \"Write a social media post about protein powder.\",\n          \"items\": [\n         {\n            \"id\": \"12345678\",\n            \"type\": \"file\",\n            \"content\": \"More information about protein powders\"\n        },\n        ],\n          \"dialogue_history\": [\n            {\n                \"prompt\": \"Can you add some more information?\",\n                \"answer\": \"Public API schemas provide necessary information to integrate with APIs...\",\n                \"created_at\": \"2013-12-12T11:20:43-08:00\"\n            }\n        ],\n          \"ai_agent\": {\n            \"type\": \"ai_agent_text_gen\",\n            \"basic_gen\": {\n              \"model\": \"azure__openai__gpt_4o_mini\"\n            }\n         }\n     }'\n```\n\n## Send text generation request to AI (extended)\n\n\u003c!-- sample post_ai_text_gen_extended--\u003e\n\n```bash\ncurl -i -L POST \"https://api.box.com/2.0/ai/text_gen\" \\\n     -H \"content-type: application/json\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -d '{\n          \"prompt\": \"Write a social media post about protein powder.\",\n          \"items\": [\n         {\n            \"id\": \"12345678\",\n            \"type\": \"file\",\n            \"content\": \"More information about protein powders\"\n        },\n        ],\n          \"dialogue_history\": [\n            {\n                \"prompt\": \"Make my email about public APIs sound more professional\",\n                \"answer\": \"Here is the first draft of your professional email about public APIs\",\n                \"created_at\": \"2013-12-12T10:53:43-08:00\"\n            },\n            {\n                \"prompt\": \"Can you add some more information?\",\n                \"answer\": \"Public API schemas provide necessary information to integrate with APIs...\",\n                \"created_at\": \"2013-12-12T11:20:43-08:00\"\n            }\n        ],\n          \"ai_agent\": {\n            \"type\": \"ai_agent_text_gen\",\n            \"basic_gen\": {\n              \"model\": \"azure__openai__gpt_4o_mini\",\n              \"system_message\": \"You are a helpful travel assistant specialized in budget travel\",\n              \"prompt_template\": \"It is `{current_date}`, and I have $8000 and want to spend a week in Azores. What should I see?\",\n              \"num_tokens_for_completion\": 8400,\n              \"llm_endpoint_params\": {\n                \"type\": \"openai_params\",\n                \"temperature\": 2.0,\n                \"top_p\": 1.0,\n                \"frequency_penalty\": 1.5,\n                \"presence_penalty\": 1.5,\n                \"stop\": \"\u003c|im_end|\u003e\"\n              },\n              \"embeddings\": {\n                \"model\": \" openai__text_embedding_ada_002\",\n                \"strategy\": {\n                  \"id\": \"basic\",\n                  \"num_tokens_per_chunk\": 64\n                }\n              },\n              \"content_template\": \"---{content}---\"\n           }\n        }\n     }'\n```\n\n## Get default agent config\n\n\u003c!-- sample get_ai_agent_default --\u003e\n\n```bash\ncurl -L GET \"https://api.box.com/2.0/ai_agent_default?mode=text_gen\" \\\n     -H 'Authorization: Bearer \u003cACCESS_TOKEN\u003e'\n```\n\n## Extract structured metadata\n\n\u003c!-- sample post_ai_extract_structured --\u003e\n\n```bash\ncurl -i -L 'https://api.box.com/2.0/ai/extract_structured' \\\n     -H 'content-type: application/json' \\\n     -H 'authorization: Bearer \u003cACCESS_TOKEN\u003e' \\\n     -d '{\n        \"items\": [\n          {\n            \"id\": \"12345678\",\n            \"type\": \"file\",\n            \"content\": \"This is file content.\"\n          }\n        ],\n        \"metadata_template\": {\n            \"template_key\": \"\",\n            \"type\": \"metadata_template\",\n            \"scope\": \"\"\n        },\n        \"fields\": [\n            {\n              \"key\": \"name\",\n              \"description\": \"The name of the person.\",\n              \"displayName\": \"Name\",\n              \"prompt\": \"The name is the first and last name from the email address.\",\n              \"type\": \"string\",\n              \"options\": [\n                {\n                  \"key\": \"First Name\"\n                },\n                {\n                  \"key\": \"Last Name\"\n                }\n              ]\n            }\n        ],\n        \"ai_agent\": {\n          \"type\": \"ai_agent_extract\",\n          \"long_text\": {\n            \"model\": \"azure__openai__gpt_4o_mini\"\n            },\n          \"basic_text\": {\n            \"model\": \"azure__openai__gpt_4o_mini\"\n         }\n      }\n   }'\n```\n\n## Extract structured metadata (extended)\n\n\u003c!-- sample post_ai_extract_structured_extended --\u003e\n\n```bash\ncurl -i -L 'https://api.box.com/2.0/ai/extract_structured' \\\n     -H 'content-type: application/json' \\\n     -H 'authorization: Bearer \u003cACCESS_TOKEN\u003e' \\\n     -d '{\n        \"items\": [\n          {\n            \"id\": \"12345678\",\n            \"type\": \"file\",\n            \"content\": \"This is file content.\"\n          }\n        ],\n        \"metadata_template\": {\n            \"template_key\": \"\",\n            \"type\": \"metadata_template\",\n            \"scope\": \"\"\n        },\n        \"fields\": [\n            {\n              \"key\": \"name\",\n              \"description\": \"The name of the person.\",\n              \"displayName\": \"Name\",\n              \"prompt\": \"The name is the first and last name from the email address.\",\n              \"type\": \"string\",\n              \"options\": [\n                {\n                  \"key\": \"First Name\"\n                },\n                {\n                  \"key\": \"Last Name\"\n                }\n              ]\n            }\n        ],\n        \"ai_agent\": {\n          \"type\": \"ai_agent_extract\",\n          \"long_text\": {\n            \"model\": \"azure__openai__gpt_4o_mini\",\n            \"system_message\": \"You are a helpful travel assistant specialized in budget travel\",\n            \"prompt_template\": \"It is `{current_date}`, and I have $8000 and want to spend a week in the Azores. What should I see?\",\n            \"num_tokens_for_completion\": 8400,\n            \"llm_endpoint_params\": {\n              \"type\": \"openai_params\",\n              \"temperature\": 0,\n              \"top_p\": 1,\n              \"frequency_penalty\": 1.5,\n              \"presence_penalty\": 1.5,\n              \"stop\": \"\u003c|im_end|\u003e\"\n            },\n            \"embeddings\": {\n              \"model\": \"openai__text_embedding_ada_002\",\n              \"strategy\": {\n                \"id\": \"basic\",\n                \"num_tokens_per_chunk\": 64\n              }\n            }\n          },\n          \"basic_text\": {\n            \"model\": \"azure__openai__gpt_4o_mini\",\n            \"system_message\": \"You are a helpful travel assistant specialized in budget travel\",\n            \"prompt_template\": \"It is `{current_date}`, and I have $8000 and want to spend a week in the Azores. What should I see?\",\n            \"num_tokens_for_completion\": 8400,\n            \"llm_endpoint_params\": {\n              \"type\": \"openai_params\",\n              \"temperature\": 0,\n              \"top_p\": 1,\n              \"frequency_penalty\": 1.5,\n              \"presence_penalty\": 1.5,\n              \"stop\": \"\u003c|im_end|\u003e\"\n            }\n          }\n        }\n    }'\n```\n\n## Extract metadata\n\n\u003c!-- sample post_ai_extract --\u003e\n\n```bash\ncurl -i -L 'https://api.box.com/2.0/ai/extract' \\\n     -H 'content-type: application/json' \\\n     -H 'authorization: Bearer \u003cACCESS_TOKEN\u003e' \\\n     -d '{\n        \"prompt\": \"Extract data related to contract conditions\",\n        \"items\": [\n              {\n                  \"type\": \"file\",\n                  \"id\": \"1497741268097\"\n              }\n        ],\n        \"ai_agent\": {\n          \"type\": \"ai_agent_extract\",\n          \"long_text\": {\n            \"model\": \"azure__openai__gpt_4o_mini\",\n            \"prompt_template\": \"It is `{current_date}`, and I have $8000 and want to spend a week in the Azores. What should I see?\",\n          },\n          \"basic_text\": {\n            \"model\": \"azure__openai__gpt_4o_mini\",\n          }\n        }\n      }'\n```\n\n## Extract metadata (extended)\n\n\u003c!-- sample post_ai_extract_extended --\u003e\n\n```bash\ncurl -i -L 'https://api.box.com/2.0/ai/extract' \\\n     -H 'content-type: application/json' \\\n     -H 'authorization: Bearer \u003cACCESS_TOKEN\u003e' \\\n     -d '{\n        \"prompt\": \"Extract data related to contract conditions\",\n        \"items\": [\n              {\n                  \"type\": \"file\",\n                  \"id\": \"1497741268097\"\n              }\n        ],\n        \"ai_agent\": {\n          \"type\": \"ai_agent_extract\",\n          \"long_text\": {\n            \"model\": \"azure__openai__gpt_4o_mini\",\n            \"system_message\": \"You are a helpful travel assistant specialized in budget travel\",\n            \"prompt_template\": \"It is `{current_date}`, and I have $8000 and want to spend a week in the Azores. What should I see?\",\n            \"num_tokens_for_completion\": 8400,\n            \"llm_endpoint_params\": {\n              \"type\": \"openai_params\",\n              \"temperature\": 0,\n              \"top_p\": 1,\n              \"frequency_penalty\": 1.5,\n              \"presence_penalty\": 1.5,\n              \"stop\": \"\u003c|im_end|\u003e\"\n            },\n            \"embeddings\": {\n              \"model\": \"openai__text_embedding_ada_002\",\n              \"strategy\": {\n                \"id\": \"basic\",\n                \"num_tokens_per_chunk\": 64\n              }\n            }\n          },\n          \"basic_text\": {\n            \"model\": \"azure__openai__gpt_4o_mini\",\n            \"system_message\": \"You are a helpful travel assistant specialized in budget travel\",\n            \"prompt_template\": \"It is `{current_date}`, and I have $8000 and want to spend a week in the Azores. What should I see?\",\n            \"num_tokens_for_completion\": 8400,\n            \"llm_endpoint_params\": {\n              \"type\": \"openai_params\",\n              \"temperature\": 0,\n              \"top_p\": 1,\n              \"frequency_penalty\": 1.5,\n              \"presence_penalty\": 1.5,\n              \"stop\": \"\u003c|im_end|\u003e\"\n            }\n          }\n        }\n      }'\n```\n\n## Add a Doc Gen template\n\n\u003c!-- sample post_docgen_templates_v2025.0 --\u003e\n\n```bash\ncurl -L 'https://api.box.com/2.0/docgen_templates' \\\n     -H 'box-version: 2025.0' \\\n     -H 'Authorization: Bearer \u003cACCESS_TOKEN\u003e' \\\n     -H 'Content-Type: application/json' \\\n     -D '{\n        \"file\": {\n            \"id\": \"12345678\",\n            \"type\": \"file\"\n        }\n}'\n```\n\n## Delete association between Doc Gen template and file\n\n\u003c!-- sample delete_docgen_templates_id_v2025.0 --\u003e\n\n```bash\ncurl -L -X DELETE 'https://api.box.com/2.0/docgen_templates/12345678' \\\n     -H 'box-version: 2025.0' \\\n     -H 'Authorization: Bearer \u003cACCESS_TOKEN\u003e'\n```\n\n## Get all Doc Gen templates\n\n\u003c!-- sample get_docgen_templates_v2025.0 --\u003e\n\n```bash\ncurl -L 'https://api.box.com/2.0/docgen_templates' \\\n     -H 'box-version: 2025.0' \\\n     -H 'Authorization: Bearer \u003cACCESS_TOKEN\u003e'\n```\n\n## Get Doc Gen template by ID\n\n\u003c!-- sample get_docgen_templates_id_v2025.0 --\u003e\n\n```bash\ncurl -L 'https://api.box.com/2.0/docgen_templates/12345678' \\\n     -H 'box-version: 2025.0' \\\n     -H 'Authorization: Bearer \u003cACCESS_TOKEN\u003e'\n```\n\n## Get Doc Gen jobs for a template\n\n\u003c!-- sample get_docgen_template_jobs_id_v2025.0 --\u003e\n\n```bash\ncurl -L 'https://api.box.com/2.0/docgen_template_jobs/12345678' \\\n     -H 'box-version: 2025.0' \\\n     -H 'Authorization: Bearer \u003cACCESS_TOKEN\u003e'\n```\n\n## Get Doc Gen template tags for template\n\n\u003c!-- sample get_docgen_templates_id_tags_v2025.0 --\u003e\n\n```bash\ncurl -L 'https://api.box.com/2.0/docgen_templates/12345678/tags' \\\n     -H 'box-version: 2025.0' \\\n     -H 'Authorization: Bearer \u003cACCESS_TOKEN\u003e'\n```\n\n## Generate a document with Doc Gen\n\n\u003c!-- sample post_docgen_batches_v2025.0 --\u003e\n\n```bash\ncurl -L 'https://api.box.com/2.0/docgen_batches' \\\n     -H 'box-version: 2025.0' \\\n     -H 'Authorization: Bearer \u003cACCESS_TOKEN\u003e' \\\n     -D '{\n        \"file\": {\n            \"id\": \"12345678\",\n            \"type\": \"file\"\n        },\n        \"input_source\": \"api\",\n        \"destination_folder\": {\n            \"id\": \"12345678\",\n            \"type\": \"folder\"\n        },\n        \"output_type\": \"docx\",\n        \"document_generation_data\": [\n            {\n                \"generated_file_name\": \"Image test\",\n                \"user_input\": {\n                    \"order\": {\n                        \"id\": \"12305\",\n                        \"date\": \"18-08-2023\",\n                        \"country\": \"US\",\n                        \"expiryDate\": \"18-08-2024\",\n                        \"currency\": \"$\",\n                        \"amount\": 5060.5,\n                        \"taxRate\": 10,\n                        \"requester\": \"John\",\n                        \"approver\": \"Smith\",\n                        \"department\": \"Procurement\",\n                        \"paymentTerms\": \"30 days\",\n                        \"deliveryTerms\": \"30 days\",\n                        \"deliveryDate\": \"18-09-2023\",\n                        \"vendor\": {\n                            \"company\": \"Example company\",\n                            \"address\": {\n                                \"street\": \"Example street\",\n                                \"city\": \"Example city\",\n                                \"zip\": \"EX-456\"\n                            }\n                        },\n                        \"products\": [\n                            {\n                                \"id\": 1,\n                                \"name\": \"A4 Papers\",\n                                \"type\": \"non-fragile\",\n                                \"quantity\": 100,\n                                \"price\": 29,\n                                \"amount\": 2900\n                            },\n                            {\n                                \"id\": 2,\n                                \"name\": \"Ink  Cartridge\",\n                                \"type\": \"non-fragile\",\n                                \"quantity\": 40,\n                                \"price\": 39,\n                                \"amount\": 1560\n                            },\n                            {\n                                \"id\": 3,\n                                \"name\": \"Adhesive tape\",\n                                \"type\": \"non-fragile\",\n                                \"quantity\": 20,\n                                \"price\": 30,\n                                \"amount\": 600.5\n                            }\n                        ]\n                    }\n                }\n            }\n        ]`\n\n```\n\n## Get all Doc Gen jobs\n\n\u003c!-- sample get_docgen_jobs_v2025.0 --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/docgen_jobs\" \\\n     -H 'box-version: 2025.0' \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get Doc Gen job by ID\n\n\u003c!-- sample get_docgen_jobs_id_v2025.0 --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/docgen_jobs/12345\" \\\n     -H 'box-version: 2025.0' \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n\n## Get Doc Gen job for a specific batch\n\n\u003c!-- sample get_docgen_batch_jobs_id_v2025.0 --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/docgen_batch_jobs/12345\" \\\n     -H 'box-version: 2025.0' \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get a file\n\nRetrieves the details about a file.\n\n\u003c!-- sample get_files_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/files/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Restore file\n\nRestores an file that has been moved to the trash.\n\n\u003c!-- sample post_files_id --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/files/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update a file\n\nUpdates a file. This can be used to rename or move a file,\ncreate a shared link, or lock a file.\n\n\u003c!-- sample put_files_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/files/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"name\": \"New name\"\n     }'\n```\n\n## Delete a file\n\nDeletes a file, either permanently or by moving it to\nthe trash.\n\nThe the enterprise settings determine whether the item will\nbe permanently deleted from Box or moved to the trash.\n\n\u003c!-- sample delete_files_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/files/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Download a file\n\nReturns the contents of a file in binary format.\n\n\u003c!-- sample get_files_id_content --\u003e\n\n```bash\ncurl -i -L -X GET \"https://api.box.com/2.0/files/12345/content\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n```\n\n## Download a file version\n\n\u003c!-- sample get_files_id_content for_version --\u003e\n\n```bash\ncurl -i -L -X GET \"https://api.box.com/2.0/files/12345/content?version=4\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n```\n\n## Get download URL\n\n\u003c!-- sample get_files_id_content get_url --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/files/12345/content?version=4\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Download a shared link\n\nReturns the contents of a file in binary format.\n\n\u003c!-- sample get_files_id_content for_shared_file --\u003e\n\n```bash\ncurl -i -L -X GET \"https://api.box.com/2.0/files/12345/content\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"boxapi: shared_link=https://cloud.box.com/shared/static/gjasdasjhasd\u0026shared_link_password=letmein\" \\\n```\n\n## Upload a file version\n\nUpdate a file's content. For file sizes over 50MB we recommend\nusing the Chunk Upload APIs.\n\n\u003c!-- sample post_files_id_content --\u003e\n\n```bash\ncurl -i -X POST \"https://upload.box.com/api/2.0/files/12345/content\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: multipart/form-data\" \\\n     -F attributes='{\"name\":\"Contract.pdf\", \"parent\":{\"id\":\"11446498\"}}' \\\n     -F file=@\u003cFILE_NAME\u003e\n```\n\n## Preflight check\n\nPerforms a check to verify that a file will be accepted by Box\nbefore you upload the entire file.\n\n\u003c!-- sample options_files_content --\u003e\n\n```bash\ncurl -i -X OPTIONS \"https://api.box.com/2.0/files/content\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\"name\":\"Contract.pdf\", \"parent\":{\"id\":\"11446498\"}}'\n```\n\n\u003c!-- sample options_files_id_content --\u003e\n\n```bash\ncurl -i -X OPTIONS \"https://api.box.com/2.0/files/12345/content\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\"name\":\"Contract.pdf\", \"parent\":{\"id\":\"11446498\"}}'\n```\n\n## Upload a file\n\nUploads a small file to Box. For file sizes over 50MB we recommend\nusing the Chunk Upload APIs.\n\n\u003c!-- sample post_files_content --\u003e\n\n```bash\ncurl -i -X POST \"https://upload.box.com/api/2.0/files/content\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: multipart/form-data\" \\\n     -F attributes='{\"name\":\"Contract.pdf\", \"parent\":{\"id\":\"11446498\"}}' \\\n     -F file=@\u003cFILE_NAME\u003e\n```\n\n## Create upload session\n\nCreates an upload session for a new file.\n\n\u003c!-- sample post_files_upload_sessions --\u003e\n\n```bash\ncurl -i -X POST \"https://upload.box.com/api/2.0/files/upload_sessions\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"folder_id\": \"0\",\n       \"file_size\": 104857600,\n       \"file_name\": \"Contract.pdf\"\n     }'\n```\n\n## Create upload session for existing file\n\nCreates an upload session for an existing file.\n\n\u003c!-- sample post_files_id_upload_sessions --\u003e\n\n```bash\ncurl -i -X POST \"https://upload.box.com/api/2.0/files/12345/upload_sessions\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"file_size\": 104857600\n     }'\n```\n\n## Get upload session\n\nReturn information about an upload session.\n\n\u003c!-- sample get_files_upload_sessions_id --\u003e\n\n```bash\ncurl -i -X GET \"https://upload.box.com/2.0/files/upload_sessions/F971964745A5CD0C001BBE4E58196BFD\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Upload a part\n\nUpdates a chunk of an upload session for a file.\n\n\u003c!-- sample put_files_upload_sessions_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://upload.box.com/2.0/files/upload_sessions/F971964745A5CD0C001BBE4E58196BFD\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"digest: sha=fpRyg5eVQletdZqEKaFlqwBXJzM=\" \\\n     -H \"content-range: bytes 8388608-16777215/445856194\" \\\n     -H \"content-type: application/octet-stream\" \\\n     --data-binary @\u003cFILE_NAME\u003e\n```\n\n## Abort upload session\n\nAbort an upload session and discard all data uploaded.\n\nThis cannot be reversed.\n\n\u003c!-- sample delete_files_upload_sessions_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://upload.box.com/2.0/files/upload_sessions/F971964745A5CD0C001BBE4E58196BFD\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List parts\n\nReturn a list of the chunks uploaded to the upload\nsession so far.\n\n\u003c!-- sample get_files_upload_sessions_id_parts --\u003e\n\n```bash\ncurl -i -X GET \"https://upload.box.com/2.0/files/upload_sessions/F971964745A5CD0C001BBE4E58196BFD/parts\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Commit upload session\n\nClose an upload session and create a file from the\nuploaded chunks.\n\n\u003c!-- sample post_files_upload_sessions_id_commit --\u003e\n\n```bash\ncurl -i -X POST \"https://upload.box.com/2.0/files/upload_sessions/F971964745A5CD0C001BBE4E58196BFD/commit\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"digest: sha=fpRyg5eVQletdZqEKaFlqwBXJzM=\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"parts\": [\n         {\n           \"part_id\": \"BFDF5379\",\n           \"offset\": 0,\n           \"size\": 8388608,\n\t     \"sha1\": \"134b65991ed521fcfe4724b7d814ab8ded5185dc\"\n         },\n\t\t     {\n           \"part_id\": \"E8A3ED8E\",\n           \"offset\": 8388608,\n           \"size\": 1611392,\n\t     \"sha1\": \"234b65934ed521fcfe3424b7d814ab8ded5185dc\"\n         }\n       ],\n       \"attributes\": {\n         \"content_modified_at\": \"2017-04-08T00:58:08Z\"\n       }\n     }'\n```\n\n## Copy a file\n\nCreates a copy of a file.\n\n\u003c!-- sample post_files_id_copy --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/files/12345/copy\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"parent\": {\n         \"id\": \"123\"\n       }\n     }'\n```\n\n## Get a file thumbnail\n\nRetrieves a thumbnail, or smaller image representation, of a file.\n\nSizes of `32x32`,`64x64`, `128x128`, and `256x256` can be returned in\nthe `.png` format and sizes of `32x32`, `94x94`, `160x160`, and `320x320`\ncan be returned in the `.jpg` format.\n\nThumbnails can be generated for the image and video file formats listed\n[found on our community site](http://community.box.com/t5/Managing-\nYour-Content/What-file-types-are-supported-by-Box-s-Content-Preview/\nta-p/327).\n\n\u003c!-- sample get_files_id_thumbnail_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/files/12345/thumbnail.png\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get file collaborations\n\nRetrieves a list of collaborations for a file. This\nreturns all the users that have access to the file.\n\n\u003c!-- sample get_files_id_collaborations --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/files/12345/collaborations\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List a file's comments\n\nRetrieves a list of comments for a file.\n\n\u003c!-- sample get_files_id_comments --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/files/12345/comments\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get file tasks\n\nRetrieves a list of all the tasks for a file. This\nendpoint does not support paging.\n\n\u003c!-- sample get_files_id_tasks --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/files/12345/tasks\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get trashed file\n\nRetrieves a file that has been moved to the trash.\n\n\u003c!-- sample get_files_id_trash --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/files/12345/trash\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Permanently delete file\n\nPermanently deletes a file that is in the trash.\nThis action cannot be undone.\n\n\u003c!-- sample delete_files_id_trash --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/files/12345/trash\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List all file versions\n\nRetrieve information on all version of a file. This endpoint can be used to\nretrieve information about older versions of a file.\n\nVersions are only tracked for Box users with premium accounts.\n\n\u003c!-- sample get_files_id_versions --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/files/12345/versions\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get a file version\n\nRetrieve a specific older version of a file.\n\nVersions are only tracked for Box users with premium accounts.\n\n\u003c!-- sample get_files_id_versions_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/files/12345/versions/456456\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Delete file version\n\nMove a file version to the trash.\n\nVersions are only tracked for Box users with premium accounts.\n\n\u003c!-- sample delete_files_id_versions_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/files/12345/versions/456456\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Promote file version\n\nPromote a specific version of a file.\n\nIf previous versions exist, this method can be used to\npromote one of the older versions to the top of the version history.\n\nThis actually creates a new copy of the old version and puts it at the\ntop of the versions history. The file will have the exact same contents\nas the older version, with the the same SHA1/etag, and the same name\nas the original.\n\nOther properties such as comments do not get updated to their\nformer values.\nDon't use this endpoint to restore Box Notes,\nas it works with file formats such as PDF, DOC, PPTX or similar.\n\n\u003c!-- sample post_files_id_versions_current --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/files/12345/versions/current\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"type\": \"file_version\",\n       \"id\": \"456456\"\n     }'\n```\n\n## Restore file version\n\nRestores a specific version of a file after it was deleted.\nDon't use this endpoint to restore Box Notes,\nas it works with file formats such as PDF, DOC, PPTX or similar.\n\n\u003c!-- sample put_files_id_versions_id --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/files/12345/versions/456456\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"trashed_at\": null\n     }'\n```\n\n## List file's metadata\n\nRetrieves all metadata for a given file.\n\n\u003c!-- sample get_files_id_metadata --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/files/12345/metadata\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get specific file metadata\n\nRetrieve a specific metadata template instance for a file\n\n\u003c!-- sample get_files_id_metadata_id_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/files/12345/metadata/enterprise_27335/blueprintTemplate\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create metadata on file\n\nCreates a piece of metadata on a file based on the specified template.\n\nOnly values that are present in the metadata template\nwill be accepted.\n\n\u003c!-- sample post_files_id_metadata_id_id --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/files/12345/metadata/enterprise_27335/blueprintTemplate\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"audience\": \"internal\",\n       \"documentType\": \"Q1 plans\",\n       \"competitiveDocument\": \"no\",\n       \"status\": \"active\",\n       \"author\": \"Jones\",\n       \"currentState\": \"proposal\"\n     }'\n\n```\n\n## Update file metadata\n\nUpdates a piece of metadata on a file.\n\nThe metadata instance can only be updated if the instance\nalready exists. When editing metadata, only values that adhere to the\nmetadata template schema will be accepted.\n\nThe update is applied atomically. If any errors occur during the\napplication of the operations, the metadata instance remains unchanged.\n\n\u003c!-- sample put_files_id_metadata_id_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/files/12345/metadata/enterprise_27335/blueprintTemplate\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json-patch+json\" \\\n     -d '[\n        {\n          \"op\": \"test\",\n          \"path\": \"/competitiveDocument\",\n          \"value\": \"no\"\n        },\n        {\n          \"op\": \"remove\",\n          \"path\": \"/competitiveDocument\"\n        },\n        {\n          \"op\": \"test\",\n          \"path\": \"/status\",\n          \"value\": \"active\"\n        },\n        {\n          \"op\": \"replace\",\n          \"path\": \"/status\",\n          \"value\": \"inactive\"\n        },\n        {\n          \"op\": \"test\",\n          \"path\": \"/author\",\n          \"value\": \"Jones\"\n        },\n        {\n          \"op\": \"copy\",\n          \"from\": \"/author\",\n          \"path\": \"/editor\"\n        },\n        {\n          \"op\": \"test\",\n          \"path\": \"/currentState\",\n          \"value\": \"proposal\"\n        },\n        {\n          \"op\": \"move\",\n          \"from\": \"/currentState\",\n          \"path\": \"/previousState\"\n        },\n        {\n          \"op\": \"add\",\n          \"path\": \"/currentState\",\n          \"value\": \"reviewed\"\n        }\n      ]'\n```\n\n## Delete file metadata\n\nDeletes a piece of file metadata.\n\n\u003c!-- sample delete_files_id_metadata_id_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/files/12345/metadata/enterprise_27335/blueprintTemplate\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get file watermark\n\nRetrieve the watermark for a file.\n\n\u003c!-- sample get_files_id_watermark --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/files/12345/watermark\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Apply watermark to file\n\nApplies or update a watermark on a file.\n\n\u003c!-- sample put_files_id_watermark --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/files/12345/watermark\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"watermark\": {\n         \"imprint\": \"default\"\n       }\n     }'\n```\n\n## Remove file watermark\n\nRemoves the watermark from a file.\n\n\u003c!-- sample delete_files_id_watermark --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/files/12345/watermark\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get a folder\n\nRetrieves details for a folder, including the first 100 entries\nin the folder.\n\nTo fetch more items within the folder, please use the\n[Get items in a folder](#get-folders-id-items) endpoint.\n\n\u003c!-- sample get_folders_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/folders/4353455\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Restore folder\n\nRestores a folder that has been moved to the trash.\n\n\u003c!-- sample post_folders_id --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/folders/4353455\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update a folder\n\nUpdates a folder. This can be also be used to move the folder,\ncreate shared links, update collaborations, and more.\n\n\u003c!-- sample put_folders_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/folders/4353455\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"name\": \"New folder name\"\n     }'\n```\n\n## Move a folder\n\n\u003c!-- sample put_folders_id move --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/folders/4353455\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"name\": \"New folder name\",\n       \"parent\": {\n         \"id\": \"123\"\n       }\n     }'\n```\n\n## Move a subfolder to a private folder\n\n\u003c!-- sample put_folders_id move_private --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/folders/4353455\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"name\": \"New folder name\",\n       \"parent\": {\n         \"id\": \"123\"\n       }\n        \"owned_by\": {\n         \"id\": \"123456\"\n       }\n     }'\n```\n\n## Rename a folder\n\n\u003c!-- sample put_folders_id rename --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/folders/4353455\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"name\": \"New folder name\"\n     }'\n```\n\n## Change folder owner\n\n\u003c!-- sample put_folders_id transfer --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/folders/4353455\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"owned_by\": {\n         \"id\": \"123\"\n       }\n     }'\n```\n\n## Delete a folder\n\nDeletes a folder, either permanently or by moving it to\nthe trash.\n\n\u003c!-- sample delete_folders_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/folders/4353455\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get items in folder\n\nRetrieves a page of items in a folder. These items can be files,\nfolders, and web links.\n\nTo request more information about the folder itself, like its size,\nplease use the [Get a folder](#get-folders-id) endpoint instead.\n\n\u003c!-- sample get_folders_id_items --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/folders/0/items\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create a folder\n\nCreates a new empty folder within the specified parent folder.\n\n\u003c!-- sample post_folders --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/folders\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"name\": \"New Folder\",\n       \"parent\": {\n         \"id\": \"0\"\n       }\n     }'\n```\n\n## Copy a folder\n\nCreates a copy of a folder within a destination folder.\n\nThe original folder will not be changed.\n\n\u003c!-- sample post_folders_id_copy --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/folders/4353455/copy\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"parent\": {\n         \"id\": \"345345\"\n       }\n     }'\n```\n\n## Get folder collaborations\n\nRetrieves a list of collaborations for a folder. This\nreturns all the users that have access to the folder.\n\n\u003c!-- sample get_folders_id_collaborations --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/folders/4353455/collaborations\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get trashed folder\n\nRetrieves a folder that has been moved to the trash.\n\n\u003c!-- sample get_folders_id_trash --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/folders/4353455/trash\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Permanently delete folder\n\nPermanently deletes a folder that is in the trash.\nThis action cannot be undone.\n\n\u003c!-- sample delete_folders_id_trash --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/folders/4353455/trash\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List folder's metadata\n\nRetrieves all metadata for a given folder.\n\n\u003c!-- sample get_folders_id_metadata --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/folders/4353455/metadata\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get specific folder metadata\n\nRetrieve a specific metadata template instance for a folder\n\n\u003c!-- sample get_folders_id_metadata_id_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/folders/4353455/metadata/enterprise_27335/blueprintTemplate\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create metadata on folder\n\nCreates a piece of metadata on a folder based on the specified template.\n\nOnly values that are present in the metadata template\nwill be accepted.\n\n\u003c!-- sample post_folders_id_metadata_id_id --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/folders/4353455/metadata/enterprise_27335/blueprintTemplate\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"audience\": \"internal\",\n       \"documentType\": \"Q1 plans\",\n       \"competitiveDocument\": \"no\",\n       \"status\": \"active\",\n       \"author\": \"Jones\",\n       \"currentState\": \"proposal\"\n     }'\n```\n\n## Update folder metadata\n\nUpdates a piece of metadata on a folder based.\n\nThe metadata instance can only be updated if the instance\nalready exists. When editing metadata, only values that adhere to the\nmetadata template schema will be accepted.\n\nThe update is applied atomically. If any errors occur during the\napplication of the operations, the metadata instance remains unchanged.\n\n\u003c!-- sample put_folders_id_metadata_id_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/folders/4353455/metadata/enterprise_27335/blueprintTemplate\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json-patch+json\" \\\n     -d '[\n        {\n          \"op\": \"test\",\n          \"path\": \"/competitiveDocument\",\n          \"value\": \"no\"\n        },\n        {\n          \"op\": \"remove\",\n          \"path\": \"/competitiveDocument\"\n        },\n        {\n          \"op\": \"test\",\n          \"path\": \"/status\",\n          \"value\": \"active\"\n        },\n        {\n          \"op\": \"replace\",\n          \"path\": \"/status\",\n          \"value\": \"inactive\"\n        },\n        {\n          \"op\": \"test\",\n          \"path\": \"/author\",\n          \"value\": \"Jones\"\n        },\n        {\n          \"op\": \"copy\",\n          \"from\": \"/author\",\n          \"path\": \"/editor\"\n        },\n        {\n          \"op\": \"test\",\n          \"path\": \"/currentState\",\n          \"value\": \"proposal\"\n        },\n        {\n          \"op\": \"move\",\n          \"from\": \"/currentState\",\n          \"path\": \"/previousState\"\n        },\n        {\n          \"op\": \"add\",\n          \"path\": \"/currentState\",\n          \"value\": \"reviewed\"\n        }\n      ]'\n```\n\n## Delete folder metadata\n\nDeletes a piece of folder metadata.\n\n\u003c!-- sample delete_folders_id_metadata_id_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/folders/4353455/metadata/enterprise_27335/blueprintTemplate\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List trashed items\n\nRetrieves the files and folders that have been moved\nto the trash.\n\nAny attribute in the full files or folders objects can be passed\nin with the `fields` parameter to retrieve those specific\nattributes that are not returned by default.\n\n\u003c!-- sample get_folders_trash_items --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/folders/trash/items\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get folder watermark\n\nRetrieve the watermark for a folder.\n\n\u003c!-- sample get_folders_id_watermark --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/folders/4353455/watermark\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Apply watermark to folder\n\nApplies or update a watermark on a folder.\n\n\u003c!-- sample put_folders_id_watermark --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/folders/4353455/watermark\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"watermark\": {\n         \"imprint\": \"default\"\n       }\n     }'\n```\n\n## Remove folder watermark\n\nRemoves the watermark from a folder.\n\n\u003c!-- sample delete_folders_id_watermark --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/folders/4353455/watermark\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get folder lock\n\nRetrieve locks applied to a folder.\n\n\u003c!-- sample get_folder_locks --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/folder_locks?folder_id=33552487093\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create folder lock\n\nCreates a lock on a folder to prevent move and / or delete operations.\n\n\u003c!-- sample post_folder_locks --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/folder_locks\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"folder\": {\n         \"type\": \"folder\",\n         \"id\": \"33552487093\"\n       },\n       \"locked_operations\": {\n         \"move\": true,\n         \"delete\": true\n       }\n     }'\n```\n\n## Delete folder lock\n\nDeletes a lock on a folder.\n\n\u003c!-- sample delete_folder_locks_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/folder_locks/93134\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get template by name\n\nRetrieves a metadata template by its scope and template name.\n\n\u003c!-- sample get_metadata_templates_id_id_schema --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/metadata_templates/enterprise/blueprintTemplate/schema\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update metadata template\n\nUpdates a metadata template.\n\nThe metadata template can only be updated if the template\nalready exists.\n\nThe update is applied atomically. If any errors occur during the\napplication of the operations, the metadata template remains unchanged.\n\n\u003c!-- sample put_metadata_templates_id_id_schema --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/metadata_templates/enterprise/blueprintTemplate/schema\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json-patch+json\" \\\n     -d '[\n       {\n         \"op\": \"editField\",\n         \"fieldKey\": \"category\",\n         \"data\": {\n           \"displayName\": \"Customer Group\"\n         }\n       }\n     ]'\n```\n\n## Delete metadata template\n\nDelete a metadata template and its instances.\nThis deletion is permanent and can not be reversed.\n\n\u003c!-- sample delete_metadata_templates_id_id_schema --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/metadata_templates/enterprise/blueprintTemplate/schema\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get a template by ID\n\nRetrieves a metadata template by its ID.\n\n\u003c!-- sample get_metadata_templates_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/metadata_templates/d9671692-3df6-11ea-b77f-2e728ce88125\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List enterprise templates\n\nUsed to retrieve all metadata templates within a user's enterprise\n\n\u003c!-- sample get_metadata_templates_enterprise --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/metadata_templates/enterprise\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List global templates\n\nUsed to retrieve all globally available metadata templates.\n\n\u003c!-- sample get_metadata_templates_global --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/metadata_templates/global\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create metadata template\n\nCreates a new metadata template that can be applied to files and folders.\n\n\u003c!-- sample post_metadata_templates_schema --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/metadata_templates/schema\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n      \"scope\": \"enterprise\",\n      \"displayName\": \"Customer\",\n      \"fields\": [\n        {\n          \"type\": \"string\",\n          \"key\": \"name\",\n          \"displayName\": \"Name\",\n          \"description\": \"The customer name\",\n          \"hidden\": false\n        },\n        {\n          \"type\": \"date\",\n          \"key\": \"last_contacted_at\",\n          \"displayName\": \"Last Contacted At\",\n          \"description\": \"When this customer was last contacted at\",\n          \"hidden\": false\n        },\n        {\n          \"type\": \"enum\",\n          \"key\": \"industry\",\n          \"displayName\": \"Industry\",\n          \"options\": [\n            {\"key\": \"Technology\"},\n            {\"key\": \"Healthcare\"},\n            {\"key\": \"Legal\"}\n          ]\n        },\n        {\n          \"type\": \"multiSelect\",\n          \"key\": \"role\",\n          \"displayName\": \"Contact Role\",\n          \"options\": [\n            {\"key\": \"Developer\"},\n            {\"key\": \"Business Owner\"},\n            {\"key\": \"Marketing\"},\n            {\"key\": \"Legal\"},\n            {\"key\": \"Sales\"}\n          ]\n        }\n      ]\n    }'\n```\n\n## List cascade policies\n\nRetrieve a collection of metadata cascade policies\nwithin a given folder for the current enterprise.\n\n\u003c!-- sample get_metadata_cascade_policies --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/metadata_cascade_policies?folder_id=31232\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create cascade policy\n\nCreates a new metadata cascade policy that applies a given\nmetadata template to a given folder and automatically\ncascades it down to its children.\n\nIn order for the policy to work, a metadata instance must first\nbe applied to the folder.\n\n\u003c!-- sample post_metadata_cascade_policies --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/metadata_cascade_policies\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"folder_id\": \"12321\",\n       \"scope\": \"enterprise_27335\",\n       \"templateKey\": \"productInfo\"\n     }'\n```\n\n## Get cascade policy\n\nRetrieve a metadata cascade policy.\n\n\u003c!-- sample get_metadata_cascade_policies_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/metadata_cascade_policies/324324\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Delete cascade policy\n\nDeletes a metadata cascade policy.\n\n\u003c!-- sample delete_metadata_cascade_policies_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/metadata_cascade_policies/324324\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Force apply cascade policy\n\nIf a policy already exists on a folder, this will apply that policy\nto all existing files and sub-folders within the target folder.\n\n\u003c!-- sample post_metadata_cascade_policies_id_apply --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/metadata_cascade_policies/21312/apply\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"conflict_resolution\": \"overwrite\"\n     }'\n```\n\n## Create a metadata query\n\n\u003c!-- sample post_metadata_queries_execute_read --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/files/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"from\": \"enterprise_123456.contractTemplate\",\n       \"query\": \"amount \u003e= :value\",\n       \"query_params\": {\n         \"value\": 100\n       },\n       \"fields\": [\n         \"created_at\",\n         \"metadata.enterprise_123456.contractTemplate.amount\",\n         \"metadata.enterprise_123456.contractTemplate.customerName\"\n       ],\n       \"ancestor_folder_id\": \"5555\",\n       \"order_by\": [\n         {\n           \"field_key\": \"amount\",\n           \"direction\": \"asc\"\n         }\n       ],\n       \"limit\": 100\n     }'\n```\n\n## Get metadata query indices\n\n\u003c!-- sample get_metadata_query_indices --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/metadata_query_indices?scope=enterprise\u0026template_key=properties\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get comment\n\nRetrieves the message and metadata for a specific comment, as well\nas information on the user who created the comment.\n\n\u003c!-- sample get_comments_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/comments/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update comment\n\nUpdate the message of a comment.\n\n\u003c!-- sample put_comments_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/comments/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"message\": \"My New Message\"\n     }'\n```\n\n## Delete comment\n\nPermanently deletes a comment.\n\n\u003c!-- sample delete_comments_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/comments/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create comment\n\nAdds a comment comment by the user to a specific file, or\nas a reply to an other comment.\n\n\u003c!-- sample post_comments --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/comments\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"message\": \"Review completed!\",\n       \"item\": {\n         \"type\": \"file\",\n         \"id\": 426436\n       }\n     }'\n```\n\n## Create reply\n\n\u003c!-- sample post_comments as_reply  --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/comments\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"message\": \"I agree with this.\",\n       \"item\": {\n         \"type\": \"comment\",\n         \"id\": 345344\n       }\n     }\n```\n\n## Tag User in Comment\n\n\u003c!-- sample post_comments tag_user --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/comments\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"tagged_message\": \"What do you think @[1234:John]?\",\n       \"item\": {\n         \"type\": \"file\",\n         \"id\": 123\n       }\n     }\n```\n\n## Tag User in Reply\n\n\u003c!-- sample post_comments as_reply_tag_user --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/comments\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"message\": \" @[1234:John], I agree with this.\",\n       \"item\": {\n         \"type\": \"comment\",\n         \"id\": 345344\n       }\n     }\n```\n\n## Get collaboration\n\nRetrieves a single collaboration.\n\n\u003c!-- sample get_collaborations_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/collaborations/1234\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update collaboration\n\nUpdates a collaboration.\n\nCan be used to change the owner of an item, or to\naccept collaboration invites.\n\n\u003c!-- sample put_collaborations_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/collaborations/1234\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"role\": \"viewer\"\n     }'\n```\n\n## Delete collaboration\n\nDeletes a single collaboration.\n\n\u003c!-- sample delete_collaborations_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/collaborations/1234\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List pending collaborations\n\nRetrieves all pending collaboration invites for this user.\n\n\u003c!-- sample get_collaborations --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/collaborations?status=pending\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create collaboration\n\nAdds a collaboration for a single user or a single group to a file\nor folder.\n\nCollaborations can be created using email address, user IDs, or a\ngroup IDs.\n\nIf a collaboration is being created with a group, access to\nthis endpoint is dependent on the group's ability to be invited.\n\n\u003c!-- sample post_collaborations--\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/collaborations\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"item\": {\n         \"type\": \"file\",\n         \"id\": \"11446498\"\n       },\n       \"accessible_by\": {\n         \"type\": \"user\",\n         \"login\": \"user@example.com\"\n       },\n       \"role\": \"editor\"\n     }'\n```\n\n\u003c!-- sample post_collaborations group--\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/collaborations\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"item\": {\n         \"type\": \"file\",\n         \"id\": \"11446498\"\n       },\n       \"accessible_by\": {\n         \"type\": \"group\",\n         \"id\": \"845344\"\n       },\n       \"role\": \"editor\"\n     }'\n```\n\n## Search for content\n\nSearches for items that are available to the user or an entire enterprise.\n\n\u003c!-- sample get_search --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/search?query=sales\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create task\n\nCreates a single task on a file.\n\n\u003c!-- sample post_tasks --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/tasks\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"item\": {\n         \"id\": \"11446498\",\n         \"type\": \"file\"\n       },\n       \"action\": \"review\"\n     }'\n```\n\n## Get task\n\nFetches a specific task.\n\n\u003c!-- sample get_tasks_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/tasks/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update task\n\nUpdates a specific task.\n\n\u003c!-- sample put_tasks_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/tasks/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"action\": \"review\"\n     }'\n```\n\n## Delete task\n\nDeletes a specific task.\n\n\u003c!-- sample delete_tasks_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/tasks/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List task's assignments\n\nRetrieves all of the assignments for a given task.\n\n\u003c!-- sample get_tasks_id_assignments --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/tasks/12345/assignments\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Assign task\n\nAssigns a task to a user.\n\nMultiple assignments to different users\nare allowed per task.\n\n\u003c!-- sample post_task_assignments --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/task_assignments\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"task\": {\n         \"id\": \"11446498\",\n         \"type\": \"task\"\n       },\n       \"assign_to\": {\n         \"id\": \"4823213\"\n       }\n     }'\n```\n\n## Get task assignment\n\nFetches a specific task assignment.\n\n\u003c!-- sample get_task_assignments_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/task_assignments/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update task assignment\n\nUpdates a task assignment. This endpoint can be\nused to update the state of a task.\n\n\u003c!-- sample put_task_assignments_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/task_assignments/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"message\": \"New message\",\n       \"resolution_state\": \"completed\"\n     }'\n```\n\n## Unassign task\n\nDeletes a specific task assignment.\n\n\u003c!-- sample delete_task_assignments_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/task_assignments/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Find item for shared link\n\nReturn the file or folder represented by a shared link.\n\nShared items are any files or folders that are represented by a shared link,\nwhich can originate within the current enterprise or within another one.\n\nThis endpoint allows an application to retrieve information about a\nshared item when only given a shared link.\n\n\u003c!-- sample get_shared_items --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/shared_items\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"boxapi: shared_link=https://app.box.com/s/gjasdasjhasd\u0026shared_link_password=letmein\"\n```\n\nThe syntax is the same regardless of wether the shared link is a file or a folder.\n\n\u003c!-- sample get_shared_items folders --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/shared_items\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"boxapi: shared_link=https://app.box.com/s/jsasdsd8sad24\u0026shared_link_password=letmein\"\n```\n\n## Create web link\n\nCreates a web link object within a folder.\n\n\u003c!-- sample post_web_links --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/web_links\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"name\": \"Cloud Content Management\",\n       \"url\": \"https://box.com\",\n       \"parent\": {\n         \"id\": \"0\"\n       }\n     }'\n```\n\n## Get web link\n\nRetrieve information about a web link.\n\n\u003c!-- sample get_web_links_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/web_links/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Restore web link\n\nRestores an web link that has been moved to the trash.\n\n\u003c!-- sample post_web_links_id --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/web_links/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update web link\n\nUpdates a web link object.\n\n\u003c!-- sample put_web_links_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/web_links/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"name\": \"Cloud Content Management\"\n     }'\n```\n\n## Delete web link\n\nDeletes a web link.\n\n\u003c!-- sample delete_web_links_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/web_links/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get trashed web link\n\nRetrieves a web link that has been moved to the trash.\n\n\u003c!-- sample get_web_links_id_trash --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/web_links/12345/trash\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Permanently delete web link\n\nPermanently deletes a web link that is in the trash.\nThis action cannot be undone.\n\n\u003c!-- sample delete_web_links_id_trash --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/web_links/12345/trash\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List enterprise users\n\nReturns a list of all users for the Enterprise along with their user_id,\npublic_name, and login.\n\nThe application and the authenticated user need to\nhave the permission to look up users in the entire\nenterprise.\n\n\u003c!-- sample get_users --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/users\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create user\n\nCreates a new managed user in an enterprise. This endpoint\nis only available to users and applications with the right\nadmin permissions.\n\n\u003c!-- sample post_users --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/users\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"login\": \"ceo@example.com\",\n       \"name\": \"Aaron Levie\"\n     }'\n```\n\n## Get authenticated user\n\nRetrieves information about the user who is currently authenticated.\n\nIn the case of a 3-legged OAuth2, client-side authenticated application\nthis will be the user who authorized the app.\n\nIn the case of a JWT, server-side authenticated application\nthis will be the service account that belongs to the application\nby default.\n\nUse the `As-User` header to change who this API call is made on behalf of.\n\n\u003c!-- sample get_users_me --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/users/me\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get user\n\nRetrieves information about a user in the enterprise.\n\nThe application and the authenticated user need to\nhave the permission to look up users in the entire\nenterprise.\n\nThis endpoint also returns a limited set of information\nfor external users who are collaborated on content\nowned by the enterprise for authenticated users with the\nright scopes. In this case, disallowed fields will return\nnull instead.\n\n\u003c!-- sample get_users_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/users/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update user\n\nUpdates a managed user in an enterprise. This endpoint\nis only available to users and applications with the right\nadmin permissions.\n\n\u003c!-- sample put_users_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/users/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"name\": \"Aaron Levie\"\n     }'\n```\n\n## Delete user\n\nDeletes a user. By default this will fail if the user\nstill owns any content. Move their owned content first\nbefore proceeding, or use the `force` field to delete\nthe user and their files.\n\n\u003c!-- sample delete_users_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/users/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get user avatar\n\nRetrieves an image of a the user's avatar.\n\n\u003c!-- sample get_users_id_avatar --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/users/12345/avatar\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Add or update user avatar\n\nUploads or updates a user avatar.\n\n\u003c!-- sample post_users_id_avatar --\u003e\n\n```bash\ncurl -i -X -L POST \"https://api.box.net/2.0/users/12345/avatar\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     --form 'pic=@\"path/to/file/file.jpeg\"'\n```\n\n## Delete user avatar\n\nDeletes a user avatar.\n\n\u003c!-- sample delete_users_id_avatar --\u003e\n\n```bash\ncurl -i -X DELETE -L \"https://api.box.net/2.0/users/12345/avatar\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Transfer owned folders\n\nMove all of the items owned by a user into a\nnew folder in another user’s account.\n\nOnly the root folder (`0`) can be transferred.\n\nFolders can only be moved across users by users with administrative\npermissions.\n\nThis call will be performed synchronously which might lead to a slow response\nwhen the source user has a large number of items in all of its folders.\n\nIf the destination path has a metadata cascade policy attached to any of\nthe parent folders, a metadata cascade operation will be kicked off\nasynchronously.\n\nThere is currently no way to check for when this operation is finished.\n\n\u003c!-- sample put_users_id_folders_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/users/12345/folders/0\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"owned_by\": {\n         \"id\": \"1232234\"\n       }\n     }'\n```\n\n## List user's email aliases\n\nRetrieves all email aliases for a user. The collection\ndoes not include the primary login for the user.\n\n\u003c!-- sample get_users_id_email_aliases --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/users/12345/email_aliases\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create email alias\n\nAdds a new email alias to a user account.\n\n\u003c!-- sample post_users_id_email_aliases --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/users/12345/email_aliases\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"email\": \"alias@example.com\"\n     }'\n```\n\n## Remove email alias\n\nRemoves an email alias from a user.\n\n\u003c!-- sample delete_users_id_email_aliases_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/users/12345/email_aliases/23432\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List user's groups\n\nRetrieves all the groups for a user. The user making\nan API call must have admin permissions to inspect the\nenterprise's groups.\n\n\u003c!-- sample get_users_id_memberships --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/users/12345/memberships\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Invite user\n\nInvites an existing external user to join an enterprise.\n\nThe existing user can not be part of another enterprise and\nmust already have a Box account. Once invited, the user will receive an\nemail and are prompted to accept the invitation within the\nBox web application.\n\nThis method requires the \"Manage An Enterprise\" scope enabled for\nthe application, which can be enabled within the developer console.\n\n\u003c!-- sample post_invites --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/invites\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"enterprise\": {\n         \"id\": \"1232234\"\n       },\n       \"actionable_by\": {\n         \"login\" : \"freeuser@box.com\"\n       }\n     }'\n```\n\n## Get user invite status\n\nReturns the status of a user invite.\n\n\u003c!-- sample get_invites_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/invites/213723\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List enterprise groups\n\nRetrieves all of the groups for a given enterprise. The user\nmust have admin permissions to inspect enterprise's groups.\n\n\u003c!-- sample get_groups --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/groups\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create group\n\nCreates a new group of users in an enterprise. Only users with admin\npermissions can create new groups.\n\n\u003c!-- sample post_groups --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/groups\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"name\": \"Customer Support\"\n     }'\n```\n\n## Get group\n\nRetrieves information about a group.\n\n\u003c!-- sample get_groups_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/groups/57645\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update group\n\nUpdates a specific group.\n\n\u003c!-- sample put_groups_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/groups/57645\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"name\": \"Customer Support\"\n     }'\n```\n\n## Delete group\n\nPermanently deletes a group.\n\n\u003c!-- sample delete_groups_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/groups/57645\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List group's members\n\nRetrieves all the members for a group. The user\nmust have admin permissions to inspect enterprise's groups.\n\n\u003c!-- sample get_groups_id_memberships --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/groups/57645/memberships\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List group's collaborations\n\nRetrieves all the collaborations for a group. The user\nmust have admin permissions to inspect enterprise's groups.\n\nEach collaboration object has details on which files or\nfolders the group has access to and with what role.\n\n\u003c!-- sample get_groups_id_collaborations --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/groups/57645/collaborations\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Add user to group\n\nCreates a group membership\n\n\u003c!-- sample post_group_memberships --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/group_memberships\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"user\": {\n         \"id\": \"1434325\"\n       },\n       \"group\": {\n         \"id\": \"4545523\"\n       }\n     }'\n```\n\n## Get group membership\n\nRetrieves a specific group membership.\n\n\u003c!-- sample get_group_memberships_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/group_memberships/434534\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update user's membership\n\nUpdates a user's group membership.\n\n\u003c!-- sample put_group_memberships_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/group_memberships/434534\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"role\": \"admin\"\n     }'\n```\n\n## Remove user from group\n\nDeletes a specific group membership.\n\n\u003c!-- sample delete_group_memberships_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/group_memberships/434534\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List all webhooks\n\nReturns all defined webhooks for the requesting application.\n\n\u003c!-- sample get_webhooks --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/webhooks\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create webhook\n\nCreates a webhook.\n\n\u003c!-- sample post_webhooks --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/webhooks\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"target\": {\n         \"id\": \"21322\",\n         \"type\": \"file\"\n       },\n       \"address\": \"https://example.com/webhooks\",\n       \"triggers\": [\n         \"FILE.PREVIEWED\"\n       ]\n     }'\n```\n\n\u003c!-- sample post_webhooks for_folder --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/webhooks\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"target\": {\n         \"id\": \"234234\",\n         \"type\": \"folder\"\n       },\n       \"address\": \"https://example.com/webhooks\",\n       \"triggers\": [\n         \"FILE.UPLOADED\"\n       ]\n     }'\n```\n\n## Get webhook\n\nRetrieves a specific webhook\n\n\u003c!-- sample get_webhooks_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/webhooks/3321123\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update webhook\n\nUpdates a webhook.\n\n\u003c!-- sample put_webhooks_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/webhooks/3321123\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"triggers\": [\n         \"FILE.DOWNLOADED\"\n       ]\n     }'\n```\n\n## Delete webhook\n\nDeletes a webhook.\n\n\u003c!-- sample delete_webhooks_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/webhooks/3321123\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update skill invocation\n\nUpdates the status, usage and response metadata of a\nskill invocation.\n\n\u003c!-- sample put_skill_invocations_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/skill_invocations/33243242\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"status\": \"success\",\n       \"metadata\": {\n         \"cards\": [{\n            \"type\": \"skill_card\",\n            \"skill_card_type\": \"keyword\",\n            \"skill_card_title\": {\n              \"code\": \"license-plates\",\n              \"message\": \"Licence Plates\"\n            },\n            \"skill\": {\n              \"type\": \"service\"\n              \"id\": \"license-plates-service\"\n            },\n            \"invocation\": {\n              \"type\": \"skill_invocation\"\n              \"id\": \"license-plates-service-123\"\n            },\n            \"entries\": {\n              { \"text\": \"DD-26-YT\" },\n              { \"text\": \"DN86 BOX\" }\n            }\n          },{\n            \"type\": \"skill_card\",\n            \"skill_card_type\": \"transcript\",\n            \"skill_card_title\": {\n              \"code\": \"video-transcription\",\n              \"message\": \"Video Transcription\"\n            },\n            \"skill\": {\n              \"type\": \"service\"\n              \"id\": \"video-transcription-service\"\n            },\n            \"invocation\": {\n              \"type\": \"skill_invocation\"\n              \"id\": \"video-transcription-service-123\"\n            },\n            \"duration\": 1000,\n            \"entries\": {\n              {\n                \"text\": \"Hi John, have I told you about Box recently?\",\n                \"appears\": [{ \"start\": 0 }]\n              },\n              {\n                \"text\": \"No Aaron, you have not. Tell me more!\",\n                \"appears\": [{ \"start\": 5 }]\n              }\n            }\n          },{\n            \"type\": \"skill_card\",\n            \"skill_card_type\": \"timeline\",\n            \"skill_card_title\": {\n              \"code\": \"face-detection\",\n              \"message\": \"Faces\"\n            },\n            \"skill\": {\n              \"type\": \"service\"\n              \"id\": \"face-detection-service\"\n            },\n            \"invocation\": {\n              \"type\": \"skill_invocation\"\n              \"id\": \"face-detection-service-123\"\n            },\n            \"duration\": 1000,\n            \"entries\": {\n              {\n                \"text\": \"John\",\n                \"appears\": [{ \"start\": 0, \"end\": 5 }, { \"start\": 10, \"end\": 15 }],\n                \"image_url\": \"https://example.com/john.png\"\n              },\n              {\n                \"text\": \"Aaron\",\n                \"appears\": [{ \"start\": 5, \"end\": 10 }],\n                \"image_url\": \"https://example.com/aaron.png\"\n              }\n            }\n          },{\n            \"type\": \"skill_card\",\n            \"skill_card_type\": \"status\",\n            \"skill_card_title\": {\n              \"code\": \"hold\",\n              \"message\": \"Please hold...\"\n            },\n            \"skill\": {\n              \"type\": \"service\"\n              \"id\": \"face-detection-service\"\n            },\n            \"invocation\": {\n              \"type\": \"skill_invocation\"\n              \"id\": \"face-detection-service-123\"\n            },\n            \"status\": {\n              \"code\": \"processing\",\n              \"message\": \"We are processing this file right now.\"\n            }\n          }],\n       },\n       \"file\": {\n         \"id\": \"12345\"\n       },\n       \"usage\": {\n         \"unit\": \"file\",\n         \"value\": 1\n       }\n     }'\n```\n\n## List Skill cards on file\n\n\u003c!-- sample get_files_id_metadata_global_boxSkillsCards --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/files/12345/metadata/global/boxSkillsCards\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create Skill cards on file\n\n\u003c!-- sample post_files_id_metadata_global_boxSkillsCards --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/files/12345/metadata/global/boxSkillsCards\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"cards\": [{\n         \"type\": \"skill_card\",\n         \"skill_card_type\": \"keyword\",\n         \"skill_card_title\": {\n           \"code\": \"license-plates\",\n           \"message\": \"Licence Plates\"\n         },\n         \"skill\": {\n           \"type\": \"service\"\n           \"id\": \"license-plates-service\"\n         },\n         \"invocation\": {\n           \"type\": \"skill_invocation\"\n           \"id\": \"license-plates-service-123\"\n         },\n         \"entries\": {\n           { \"text\": \"DD-26-YT\" },\n           { \"text\": \"DN86 BOX\" }\n         }\n       },{\n         \"type\": \"skill_card\",\n         \"skill_card_type\": \"transcript\",\n         \"skill_card_title\": {\n           \"code\": \"video-transcription\",\n           \"message\": \"Video Transcription\"\n         },\n         \"skill\": {\n           \"type\": \"service\"\n           \"id\": \"video-transcription-service\"\n         },\n         \"invocation\": {\n           \"type\": \"skill_invocation\"\n           \"id\": \"video-transcription-service-123\"\n         },\n         \"duration\": 1000,\n         \"entries\": {\n           {\n             \"text\": \"Hi John, have I told you about Box recently?\",\n             \"appears\": [{ \"start\": 0 }]\n           },\n           {\n             \"text\": \"No Aaron, you have not. Tell me more!\",\n             \"appears\": [{ \"start\": 5 }]\n           }\n         }\n       },{\n         \"type\": \"skill_card\",\n         \"skill_card_type\": \"timeline\",\n         \"skill_card_title\": {\n           \"code\": \"face-detection\",\n           \"message\": \"Faces\"\n         },\n         \"skill\": {\n           \"type\": \"service\"\n           \"id\": \"face-detection-service\"\n         },\n         \"invocation\": {\n           \"type\": \"skill_invocation\"\n           \"id\": \"face-detection-service-123\"\n         },\n         \"duration\": 1000,\n         \"entries\": {\n           {\n             \"text\": \"John\",\n             \"appears\": [{ \"start\": 0, \"end\": 5 }, { \"start\": 10, \"end\": 15 }],\n             \"image_url\": \"https://example.com/john.png\"\n           },\n           {\n             \"text\": \"Aaron\",\n             \"appears\": [{ \"start\": 5, \"end\": 10 }],\n             \"image_url\": \"https://example.com/aaron.png\"\n           }\n         }\n       },{\n         \"type\": \"skill_card\",\n         \"skill_card_type\": \"status\",\n         \"skill_card_title\": {\n           \"code\": \"hold\",\n           \"message\": \"Please hold...\"\n         },\n         \"skill\": {\n           \"type\": \"service\"\n           \"id\": \"face-detection-service\"\n         },\n         \"invocation\": {\n           \"type\": \"skill_invocation\"\n           \"id\": \"face-detection-service-123\"\n         },\n         \"status\": {\n           \"code\": \"processing\",\n           \"message\": \"We are processing this file right now.\"\n         }\n       }],\n     }'\n```\n\n## Update Skill cards on file\n\n\u003c!-- sample put_files_id_metadata_global_boxSkillsCards --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/files/12345/metadata/global/boxSkillsCards\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json-patch+json\" \\\n     -d '[\n       \"op\": \"replace\",\n       \"path\": \"/cards/0\",\n       \"value\": {\n         \"type\": \"skill_card\",\n         \"skill_card_type\": \"keyword\",\n         \"skill_card_title\": {\n           \"code\": \"license-plates\",\n           \"message\": \"Licence Plates\"\n         },\n         \"skill\": {\n           \"type\": \"service\"\n           \"id\": \"license-plates-service\"\n         },\n         \"invocation\": {\n           \"type\": \"skill_invocation\"\n           \"id\": \"license-plates-service-123\"\n         },\n         \"entries\": {\n           { \"text\": \"DD-26-YT\" },\n           { \"text\": \"DN86 BOX\" }\n         }\n       }\n     ]'\n```\n\n## Delete Skill cards from file\n\n\u003c!-- sample delete_files_id_metadata_global_boxSkillsCards --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/files/12345/metadata/global/boxSkillsCards\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get a long poll endpoint\n\nReturns a list of real-time servers that can be used for long-polling updates\nto the [event stream](#get-events).\n\nLong polling is the concept where a HTTP request is kept open until the\nserver sends a response, then repeating the process over and over to receive\nupdated responses.\n\nLong polling the event stream can only be used for user events, not for\nenterprise events.\n\nTo use long polling, first use this endpoint to retrieve a list of long poll\nURLs. Next, make a long poll request to any of the provided URLs.\n\nWhen an event occurs in monitored account a response with the value\n`new_change` will be sent. The response contains no other details as\nit simply serves as a prompt to take further action such as sending a\nrequest to the [events endpoint](#get-events) with the last known\n`stream_position`.\n\nAfter the server sends this response it closes the connection. You must now\nrepeat the long poll process to begin listening for events again.\n\nIf no events occur for a while and the connection times out you will\nreceive a response with the value `reconnect`. When you receive this response\nyou’ll make another call to this endpoint to restart the process.\n\nIf you receive no events in `retry_timeout` seconds then you will need to\nmake another request to the real-time server (one of the URLs in the response\nfor this endpoint). This might be necessary due to network errors.\n\nFinally, if you receive a `max_retries` error when making a request to the\nreal-time server, you should start over by making a call to this endpoint\nfirst.\n\n\u003c!-- sample options_events --\u003e\n\n```bash\ncurl -i -X OPTIONS \"https://api.box.com/2.0/events\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get user and enterprise events\n\nReturns up to a year of past events for a given user\nor for the entire enterprise.\n\nBy default this returns events for the authenticated user. To retrieve\nevents for the entire enterprise, set the `stream_type` to `admin_logs`\n(historical - 1 year) or `admin_logs_streaming` (live - two weeks). The user\nmaking the API call will need to have admin privileges, and the application will\nneed to have the permission to access the event feed to get the enterprise event\nfeed.\n\n\u003c!-- sample get_events --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/events\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n\u003c!-- sample get_events enterprise --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/events?stream_type=admin_logs\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n\u003c!-- sample get_events enterprise_filter --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/events?stream_type=admin_logs\u0026event_type=LOGIN,FAILED_LOGIN\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n\u003c!-- sample get_events enterprise_stream --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/events?stream_type=admin_logs_streaming\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n\u003c!-- sample get_events enterprise_stream_filter --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/events?stream_type=admin_logs_streaming\u0026event_type=LOGIN,FAILED_LOGIN\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List all collections\n\nRetrieves all collections for a given user.\n\nCurrently, only the `favorites` collection\nis supported.\n\n\u003c!-- sample get_collections --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/collections\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List collection items\n\nRetrieves the files and/or folders contained within\nthis collection.\n\n\u003c!-- sample get_collections_id_items --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/collections/926489/items\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Add file to collection\n\n\u003c!-- sample put_files_id add_to_collection --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/files/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"collections\": [\n          {\n            \"id\": \"123\"\n          }\n       ]\n     }'\n```\n\n## Add folder to collection\n\n\u003c!-- sample put_folders_id add_to_collection --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/folders/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"collections\": [\n          {\n            \"id\": \"123\"\n          }\n       ]\n     }'\n```\n\n## Add web link to collection\n\n\u003c!-- sample put_web_links_id add_to_collection --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/web_links/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"collections\": [\n          {\n            \"id\": \"123\"\n          }\n       ]\n     }'\n```\n\n## Remove file from collection\n\n\u003c!-- sample put_files_id remove_from_collection --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/files/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"collections\": []\n     }'\n```\n\n## Remove folder from collection\n\n\u003c!-- sample put_folders_id remove_from_collection --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/folders/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"collections\": []\n     }'\n```\n\n## Remove web link from collection\n\n\u003c!-- sample put_web_links_id remove_from_collection --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/web_links/12345\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"collections\": []\n     }'\n```\n\n## List recent items\n\nReturns information about the recent items accessed\nby a user, either in the last 90 days or up to the last\n1000 items accessed.\n\n\u003c!-- sample get_recent_items --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/recent_items\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List retention policies\n\nRetrieves all of the retention policies for an enterprise.\n\n\u003c!-- sample get_retention_policies --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/retention_policies\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create retention policy\n\nCreates a retention policy.\n\n\u003c!-- sample post_retention_policies --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/retention_policies\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"policy_name\": \"Some Policy Name\",\n       \"policy_type\": \"finite\",\n       \"retention_length\": 365,\n       \"disposition_action\": \"permanently_delete\"\n     }'\n```\n\n## Get retention policy\n\nRetrieves a retention policy.\n\n\u003c!-- sample get_retention_policies_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/retention_policies/982312\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update retention policy\n\nUpdates a retention policy.\n\n\u003c!-- sample put_retention_policies_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/retention_policies/982312\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"disposition_action\": \"permanently_delete\"\n     }'\n```\n\n## List policy's assignments\n\nReturns a list of all retention policy assignments associated with a specified\nretention policy.\n\n\u003c!-- sample get_retention_policies_id_assignments --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/retention_policies/982312/assignments\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Assign retention policy\n\nAssigns a retention policy to an item.\n\n\u003c!-- sample post_retention_policy_assignments --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/retention_policy_assignments\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"policy_id\": \"173463\",\n       \"assign_to\": {\n         \"type\": \"folder\",\n         \"id\": \"6564564\"\n       }\n     }'\n```\n\n## Get policy assignment\n\nRetrieves a retention policy assignment\n\n\u003c!-- sample get_retention_policy_assignments_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/retention_policy_assignments/1233123\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List all legal hold policies\n\nRetrieves a list of legal hold policies that belong to\nan enterprise.\n\n\u003c!-- sample get_legal_hold_policies --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/legal_hold_policies\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create legal hold policy\n\nCreate a new legal hold policy.\n\n\u003c!-- sample post_legal_hold_policies --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/legal_hold_policies\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"policy_name\": \"Policy 3\",\n       \"description\": \"Automatic created policy\"\n     }'\n```\n\n## Get legal hold policy\n\nRetrieve a legal hold policy.\n\n\u003c!-- sample get_legal_hold_policies_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/legal_hold_policies/324432\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Update legal hold policy\n\nUpdate legal hold policy.\n\n\u003c!-- sample put_legal_hold_policies_id --\u003e\n\n```bash\ncurl -i -X PUT \"https://api.box.com/2.0/legal_hold_policies/324432\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"policy_name\": \"Policy 4\"\n     }'\n```\n\n## Delete legal hold policy\n\nDelete an existing legal hold policy.\n\nThis is an asynchronous process. The policy will not be\nfully deleted yet when the response returns.\n\n\u003c!-- sample delete_legal_hold_policies_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/legal_hold_policies/324432\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List policy's assignments\n\nRetrieves a list of items a legal hold policy has been assigned to.\n\n\u003c!-- sample get_legal_hold_policy_assignments --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/legal_hold_policy_assignments?policy_id=324432\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Assign legal hold policy\n\nAssign a legal hold to a file, file version, folder, or user.\n\n\u003c!-- sample post_legal_hold_policy_assignments --\u003e\n\n```bash\ncurl -i -X POST \"https://api.box.com/2.0/legal_hold_policy_assignments\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\" \\\n     -H \"content-type: application/json\" \\\n     -d '{\n       \"policy_id\": \"123244\",\n       \"assign_to\": {\n         \"type\": \"folder\",\n         \"id\": \"6564564\"\n       }\n     }'\n```\n\n## Get policy assignment\n\nRetrieve a legal hold policy assignment.\n\n\u003c!-- sample get_legal_hold_policy_assignments_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/legal_hold_policy_assignments/753465\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Unassign legal hold policy\n\nRemove a legal hold from an item.\n\nThis is an asynchronous process. The policy will not be\nfully removed yet when the response returns.\n\n\u003c!-- sample delete_legal_hold_policy_assignments_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/legal_hold_policy_assignments/753465\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get retention for file\n\nReturns information about a file version retention.\n\n\u003c!-- sample get_file_version_retentions_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/file_version_retentions/3424234\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List retentions on files\n\nRetrieves all file version retentions for the given enterprise.\n\n\u003c!-- sample get_file_version_retentions --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/file_version_retentions\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List files under retention for a retention policy\n\nRetrieves all files for the given retention policy id.\n\n\u003c!-- sample get_retention_policy_assignments_id_files_under_retention --\u003e\n\n```bash\ncurl -i -X GET \"https://app.box.com/api/2.0/retention_policy_assignments/3424234/files_under_retention\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List file versions under retention for a retention policy\n\nRetrieves all file versions for the given retention policy id.\n\n\u003c!-- sample get_retention_policy_assignments_id_file_versions_under_retention --\u003e\n\n```bash\ncurl -i -X GET \"https://app.box.com/api/2.0/retention_policy_assignments/3424234/file_versions_under_retention\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Inspect legal hold on file\n\nRetrieves information about the legal hold policies\nassigned to a file version.\n\n\u003c!-- sample get_file_version_legal_holds_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/file_version_legal_holds/2348213\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List legal holds for policy\n\nGet list of non-deleted legal holds for a single legal\nhold policy.\n\n\u003c!-- sample get_file_version_legal_holds --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/file_version_legal_holds?policy_id=133870\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Get device pin\n\nRetrieves information about an individual device pin.\n\n\u003c!-- sample get_device_pinners_id --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/device_pinners/2324234\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Delete device pin\n\nDeletes an individual device pin.\n\n\u003c!-- sample delete_device_pinners_id --\u003e\n\n```bash\ncurl -i -X DELETE \"https://api.box.com/2.0/device_pinners/2324234\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List enterprise device pins\n\nRetrieves all the device pins within an enterprise.\n\nThe user must have admin privileges, and the application\nneeds the \"manage enterprise\" scope to make this call.\n\n\u003c!-- sample get_enterprises_id_device_pinners --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/enterprises/3442311/device_pinners\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## List terms of services\n\nReturns the current terms of service text and settings\nfor the enterprise.\n\n\u003c!-- sample get_terms_of_services --\u003e\n\n```bash\ncurl -i -X GET \"https://api.box.com/2.0/terms_of_services\" \\\n     -H \"authorization: Bearer \u003cACCESS_TOKEN\u003e\"\n```\n\n## Create terms of service\n\nCreates a terms of service for a given enterprise\nand type of user.\n\n\u003c!-- sample post_terms_of_services --\u003e\n\n```bash\ncurl -i -X ","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbox-community%2Fbox-curl-samples","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbox-community%2Fbox-curl-samples","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbox-community%2Fbox-curl-samples/lists"}