import{r as o,p as i,q as h,w as e,z as s,t as n,R as t}from"./vendor.3d5b4206.js";const d={class:"markdown-body"},p=s("div",{class:"two-up"},[s("div",{class:"left"},[s("blockquote",null,[s("p",null,"Settings are key-value pairs that are stored in the database, and control different aspects of the project. Only administrators have access to manage Settings.")])]),s("div",{class:"right"},[s("p",null,[s("div",{class:"table-of-contents"},[s("ul",null,[s("li",null,[s("a",{href:"#the-settings-object"},"The Settings Object")]),s("li",null,[s("a",{href:"#retrieve-settings"},"Retrieve Settings")]),s("li",null,[s("a",{href:"#update-settings"},"Update Settings")])])])])])],-1),_=s("hr",null,null,-1),u=s("h2",{id:"the-settings-object"},[t("The Settings Object "),s("a",{class:"header-anchor",href:"#the-settings-object"},"#")],-1),g={class:"two-up"},j={class:"left"},f={class:"definitions"},m=s("p",null,[s("code",null,"id"),t(),s("strong",null,"uuid"),s("br"),t(" Primary key of the setting.")],-1),b=s("p",null,[s("code",null,"project_name"),t(),s("strong",null,"string"),s("br"),t(" Name of the project, shown in the Admin App.")],-1),y=s("p",null,[s("code",null,"project_descriptor"),t(),s("strong",null,"string"),s("br"),t(" Descriptor of the project, shown in the Admin App.")],-1),v=s("p",null,[s("code",null,"project_url"),t(),s("strong",null,"string"),s("br"),t(" Link to the (public) website that goes with this project.")],-1),q=s("p",null,[s("code",null,"project_color"),t(),s("strong",null,"string"),s("br"),t(" Brand color for the current project.")],-1),w=s("code",null,"project_logo",-1),x=t(),k=s("strong",null,"many-to-one",-1),A=s("br",null,null,-1),S=t(" Primary logo for the current project. Many-to-one to "),R=t("files"),T=t("."),P=s("code",null,"public_foreground",-1),E=t(),C=s("strong",null,"many-to-one",-1),M=s("br",null,null,-1),B=t(" Foreground image for the Admin App\u2019s public pages. Many-to-one to "),O=t("files"),D=t("."),N=s("code",null,"public_background",-1),Q=t(),W=s("strong",null,"many-to-one",-1),G=s("br",null,null,-1),H=t(" Background image for the Admin App\u2019s public pages. Many-to-one to "),I=t("files"),L=t("."),V=s("p",null,[s("code",null,"public_note"),t(),s("strong",null,"string"),s("br"),t(" Note shown on the Admin App\u2019s public pages. Supports Markdown.")],-1),F=s("p",null,[s("code",null,"auth_login_attempts"),t(),s("strong",null,"integer"),s("br"),t(" How often a user is allowed to try to login. After which times the user will be suspended.")],-1),U=s("p",null,[s("code",null,"auth_password_policy"),t(),s("strong",null,"RegEx"),s("br"),t(" What regex passwords must pass in order to be valid.")],-1),z=s("code",null,"storage_asset_transform",-1),J=t(),K=s("strong",null,"string",-1),X=s("br",null,null,-1),Y=t(" If the transform endpoints are allowed to be used on "),Z=t("the assets endpoint"),$=t(". One of "),ss=s("code",null,"all",-1),ts=t(", "),es=s("code",null,"none",-1),ls=t(" or "),ns=s("code",null,"presets",-1),as=t("."),os=s("code",null,"storage_asset_presets",-1),rs=t(),cs=s("strong",null,"array",-1),is=s("br",null,null,-1),hs=t(" What preset keys exist in "),ds=t("the assets endpoint"),ps=t("."),_s=s("p",null,[s("code",null,"custom_css"),t(),s("strong",null,"string"),s("br"),t(" CSS rules to override the App\u2019s default styling.")],-1),us=s("p",null,[s("code",null,"storage_default_folder"),t(),s("strong",null,"uuid"),s("br"),t(" Folder for uploaded files. Does not affect existing files.")],-1),gs=s("p",null,[s("code",null,"basemaps"),t(),s("strong",null,"array"),s("br"),t(" Custom tiles to overriding the Mapbox defaults.")],-1),js=s("p",null,[s("code",null,"mapbox_key"),t(),s("strong",null,"string"),s("br"),s("a",{href:"https://docs.mapbox.com/help/glossary/access-token/",target:"_blank",rel:"noopener noreferrer"},"Mapbox Access Token"),t(".")],-1),fs=s("p",null,[s("code",null,"module_bar"),t(),s("strong",null,"array"),s("br"),t(" What modules are enabled/added globally.")],-1),ms=s("div",{class:"right"},[s("pre",null,[s("code",{class:"language-json"},[t(`{
	`),s("span",{class:"hljs-attr"},'"data"'),t(`: {
		`),s("span",{class:"hljs-attr"},'"id"'),t(": "),s("span",{class:"hljs-number"},"1"),t(`,
		`),s("span",{class:"hljs-attr"},'"project_name"'),t(": "),s("span",{class:"hljs-string"},'"Directus"'),t(`,
		`),s("span",{class:"hljs-attr"},'"project_descriptor"'),t(": "),s("span",{class:"hljs-string"},'"Application"'),t(`,
		`),s("span",{class:"hljs-attr"},'"project_url"'),t(": "),s("span",{class:"hljs-literal"},"null"),t(`,
		`),s("span",{class:"hljs-attr"},'"project_color"'),t(": "),s("span",{class:"hljs-literal"},"null"),t(`,
		`),s("span",{class:"hljs-attr"},'"project_logo"'),t(": "),s("span",{class:"hljs-literal"},"null"),t(`,
		`),s("span",{class:"hljs-attr"},'"public_foreground"'),t(": "),s("span",{class:"hljs-literal"},"null"),t(`,
		`),s("span",{class:"hljs-attr"},'"public_background"'),t(": "),s("span",{class:"hljs-literal"},"null"),t(`,
		`),s("span",{class:"hljs-attr"},'"public_note"'),t(": "),s("span",{class:"hljs-literal"},"null"),t(`,
		`),s("span",{class:"hljs-attr"},'"auth_login_attempts"'),t(": "),s("span",{class:"hljs-number"},"25"),t(`,
		`),s("span",{class:"hljs-attr"},'"auth_password_policy"'),t(": "),s("span",{class:"hljs-literal"},"null"),t(`,
		`),s("span",{class:"hljs-attr"},'"storage_asset_transform"'),t(": "),s("span",{class:"hljs-string"},'"all"'),t(`,
		`),s("span",{class:"hljs-attr"},'"storage_asset_presets"'),t(`: [
			{ `),s("span",{class:"hljs-attr"},'"key"'),t(": "),s("span",{class:"hljs-string"},'"small"'),t(", "),s("span",{class:"hljs-attr"},'"fit"'),t(": "),s("span",{class:"hljs-string"},'"cover"'),t(", "),s("span",{class:"hljs-attr"},'"width"'),t(": "),s("span",{class:"hljs-number"},"200"),t(", "),s("span",{class:"hljs-attr"},'"height"'),t(": "),s("span",{class:"hljs-number"},"161"),t(", "),s("span",{class:"hljs-attr"},'"quality"'),t(": "),s("span",{class:"hljs-number"},"80"),t(", "),s("span",{class:"hljs-attr"},'"withoutEnlargement"'),t(": "),s("span",{class:"hljs-literal"},"false"),t(` }
		],
		`),s("span",{class:"hljs-attr"},'"custom_css"'),t(": "),s("span",{class:"hljs-literal"},"null"),t(`,
		`),s("span",{class:"hljs-attr"},'"storage_default_folder"'),t(": "),s("span",{class:"hljs-literal"},"null"),t(`,
		`),s("span",{class:"hljs-attr"},'"basemaps"'),t(": "),s("span",{class:"hljs-literal"},"null"),t(`,
		`),s("span",{class:"hljs-attr"},'"mapbox_key"'),t(": "),s("span",{class:"hljs-literal"},"null"),t(`,
		`),s("span",{class:"hljs-attr"},'"module_bar"'),t(": "),s("span",{class:"hljs-literal"},"null"),t(`
	}
}
`)])])],-1),bs=s("hr",null,null,-1),ys=s("h2",{id:"retrieve-settings"},[t("Retrieve Settings "),s("a",{class:"header-anchor",href:"#retrieve-settings"},"#")],-1),vs={class:"two-up"},qs={class:"left"},ws=s("h3",{id:"query-parameters"},[t("Query Parameters "),s("a",{class:"header-anchor",href:"#query-parameters"},"#")],-1),xs=t("Supports all "),ks=t("global query parameters"),As=t("."),Ss=s("h3",{id:"returns"},[t("Returns "),s("a",{class:"header-anchor",href:"#returns"},"#")],-1),Rs=s("p",null,[t("Returns the "),s("a",{href:"#the-settings-object"},"settings object"),t(".")],-1),Ts=s("div",{class:"right"},[s("h3",{id:"rest-api"},[t("REST API "),s("a",{class:"header-anchor",href:"#rest-api"},"#")]),s("pre",null,[s("code",null,`GET /settings
`)]),s("h3",{id:"graphql"},[t("GraphQL "),s("a",{class:"header-anchor",href:"#graphql"},"#")]),s("pre",null,[s("code",null,`POST /graphql/system
`)]),s("pre",null,[s("code",{class:"language-graphql"},[s("span",{class:"hljs-keyword"},"type"),s("span",{class:"hljs-type"}," Query"),t(` {
	settings: directus_settings
}
`)])]),s("h5",{id:"example"},[t("Example "),s("a",{class:"header-anchor",href:"#example"},"#")]),s("pre",null,[s("code",{class:"language-graphql"},[s("span",{class:"hljs-keyword"},"query"),t(` {
	settings {
		project_name
	}
}
`)])])],-1),Ps=s("hr",null,null,-1),Es=s("h2",{id:"update-settings"},[t("Update Settings "),s("a",{class:"header-anchor",href:"#update-settings"},"#")],-1),Cs={class:"two-up"},Ms={class:"left"},Bs=s("h3",{id:"query-parameters-2"},[t("Query Parameters "),s("a",{class:"header-anchor",href:"#query-parameters-2"},"#")],-1),Os=t("Supports all "),Ds=t("global query parameters"),Ns=t("."),Qs=s("h3",{id:"request-body"},[t("Request Body "),s("a",{class:"header-anchor",href:"#request-body"},"#")],-1),Ws=s("p",null,[t("A partial "),s("a",{href:"#the-settings-object"},"settings object"),t(".")],-1),Gs=s("h3",{id:"returns-2"},[t("Returns "),s("a",{class:"header-anchor",href:"#returns-2"},"#")],-1),Hs=s("p",null,[t("Returns the "),s("a",{href:"#the-setting-object"},"settings object"),t(".")],-1),Is=s("div",{class:"right"},[s("h3",{id:"rest-api-2"},[t("REST API "),s("a",{class:"header-anchor",href:"#rest-api-2"},"#")]),s("pre",null,[s("code",null,`PATCH /settings
`)]),s("h5",{id:"example-2"},[t("Example "),s("a",{class:"header-anchor",href:"#example-2"},"#")]),s("pre",null,[s("code",{class:"language-json"},[s("span",{class:"hljs-comment"},"// PATCH /settings"),t(`

{
	`),s("span",{class:"hljs-attr"},'"project_url"'),t(": "),s("span",{class:"hljs-string"},'"https://example.com/"'),t(`
}
`)])]),s("h3",{id:"graphql-2"},[t("GraphQL "),s("a",{class:"header-anchor",href:"#graphql-2"},"#")]),s("pre",null,[s("code",null,`POST /graphql/system
`)]),s("pre",null,[s("code",{class:"language-graphql"},[s("span",{class:"hljs-keyword"},"type"),s("span",{class:"hljs-type"}," Mutation"),t(` {
	update_settings(data: update_directus_settings_input!): directus_settings
}
`)])]),s("h5",{id:"example-3"},[t("Example "),s("a",{class:"header-anchor",href:"#example-3"},"#")]),s("pre",null,[s("code",{class:"language-graphql"},[s("span",{class:"hljs-keyword"},"mutation"),t(` {
	update_settings(data: { project_url: `),s("span",{class:"hljs-string"},'"https://example.com"'),t(` }) {
		project_name
		project_url
	}
}
`)])])],-1),zs={setup(Ls,{expose:r}){const a={title:"Settings",modularExtension:!1,pageClass:"page-reference"};return r({frontmatter:a}),(Vs,Fs)=>{const l=o("router-link"),c=o("DocsWrapper");return i(),h(c,{frontmatter:a},{default:e(()=>[s("div",d,[p,_,u,s("div",g,[s("div",j,[s("div",f,[m,b,y,v,q,s("p",null,[w,x,k,A,S,n(l,{to:"/docs/reference/files/"},{default:e(()=>[R]),_:1}),T]),s("p",null,[P,E,C,M,B,n(l,{to:"/docs/reference/files/"},{default:e(()=>[O]),_:1}),D]),s("p",null,[N,Q,W,G,H,n(l,{to:"/docs/reference/files/"},{default:e(()=>[I]),_:1}),L]),V,F,U,s("p",null,[z,J,K,X,Y,n(l,{to:"/docs/reference/files/#requesting-a-thumbnail"},{default:e(()=>[Z]),_:1}),$,ss,ts,es,ls,ns,as]),s("p",null,[os,rs,cs,is,hs,n(l,{to:"/docs/reference/files/#requesting-a-thumbnail"},{default:e(()=>[ds]),_:1}),ps]),_s,us,gs,js,fs])]),ms]),bs,ys,s("div",vs,[s("div",qs,[ws,s("p",null,[xs,n(l,{to:"/docs/reference/query"},{default:e(()=>[ks]),_:1}),As]),Ss,Rs]),Ts]),Ps,Es,s("div",Cs,[s("div",Ms,[Bs,s("p",null,[Os,n(l,{to:"/docs/reference/query"},{default:e(()=>[Ds]),_:1}),Ns]),Qs,Ws,Gs,Hs]),Is])])]),_:1})}}};export{zs as default};
