[{"data":1,"prerenderedAt":1208,"buildId":1209},["ShallowReactive",2],{"page:\u002Fdocs\u002F5.x\u002Fintegrations\u002Fgitlab":3},{"id":4,"title":5,"body":6,"description":1192,"extension":1193,"frontmatter":1194,"heading":5,"meta":1200,"navigation":1201,"order":1196,"path":1202,"seo":1203,"sitemap":1204,"source":1205,"stem":1206,"__hash__":1207},"docs\u002Fdocs\u002F5.x\u002Fintegrations\u002Fgitlab.md","Publish Kubb snapshots with GitLab CI",{"type":7,"value":8,"toc":1185},"minimark",[9,32,37,52,164,195,215,219,226,264,307,1174],[10,11,12,13,17,18,23,24,27,28,31],"p",{},"A GitLab job runs ",[14,15,16],"code",{},"kubb studio snapshot"," on each merge request and protected branch. Meet the ",[19,20,22],"a",{"href":21},"\u002Fdocs\u002F5.x\u002Fintegrations\u002Fci#prerequisites","prerequisites"," first: Kubb 5.6.2 or later, ",[14,25,26],{},"tsdown",", and a CI key stored as ",[14,29,30],{},"KUBB_TOKEN",".",[33,34,36],"h2",{"id":35},"add-the-job","Add the job",[10,38,39,40,42,43,47,48,51],{},"Store ",[14,41,30],{}," as a masked and ",[44,45,46],"strong",{},"Protected"," CI\u002FCD variable, so only pipelines for protected branches get it. Commit your npm lockfile, so ",[14,49,50],{},"npm ci"," is the only setup:",[53,54,59],"pre",{"language":55,"filename":56,"code":57,"class":58},"yaml",".gitlab-ci.yml","snapshot:\n stage: build\n image: node:22\n script:\n - npm ci\n - npx kubb studio snapshot\n rules:\n - if: $CI_PIPELINE_SOURCE == \"merge_request_event\" && $KUBB_TOKEN\n - if: $CI_COMMIT_BRANCH && $CI_COMMIT_REF_PROTECTED == \"true\" && $KUBB_TOKEN","highlights",[14,60,62,75,76,75,91,75,103,75,112,75,119,75,130,75,139,75,151],{"class":61},"language-yaml",[63,64,67,71],"span",{"class":65,"style":66},"line","display: inline",[63,68,70],{"style":69},"color:#005cc5;--hls-dark:#79b8ff","snapshot",[63,72,74],{"style":73},"color:#d73a49;--hls-dark:#f97583",":","\n",[63,77,78,81,84,87],{"class":65,"style":66},[63,79,80],{"style":73}," ",[63,82,83],{"style":69},"stage",[63,85,86],{"style":73},": ",[63,88,90],{"style":89},"color:#032f62;--hls-dark:#9ecbff","build",[63,92,93,95,98,100],{"class":65,"style":66},[63,94,80],{"style":89},[63,96,97],{"style":69},"image",[63,99,86],{"style":73},[63,101,102],{"style":89},"node:22",[63,104,105,107,110],{"class":65,"style":66},[63,106,80],{"style":89},[63,108,109],{"style":69},"script",[63,111,74],{"style":73},[63,113,114,117],{"class":65,"style":66},[63,115,116],{"style":73}," - ",[63,118,50],{"style":89},[63,120,121,124,127],{"class":65,"style":66},[63,122,123],{"style":89}," ",[63,125,126],{"style":73},"- ",[63,128,129],{"style":89},"npx kubb studio snapshot",[63,131,132,134,137],{"class":65,"style":66},[63,133,80],{"style":89},[63,135,136],{"style":69},"rules",[63,138,74],{"style":73},[63,140,141,143,146,148],{"class":65,"style":66},[63,142,116],{"style":73},[63,144,145],{"style":69},"if",[63,147,86],{"style":73},[63,149,150],{"style":89},"$CI_PIPELINE_SOURCE == \"merge_request_event\" && $KUBB_TOKEN",[63,152,153,155,157,159,161],{"class":65,"style":66},[63,154,123],{"style":89},[63,156,126],{"style":73},[63,158,145],{"style":69},[63,160,86],{"style":73},[63,162,163],{"style":89},"$CI_COMMIT_BRANCH && $CI_COMMIT_REF_PROTECTED == \"true\" && $KUBB_TOKEN",[165,166,167,175,186],"ul",{},[168,169,170,171,174],"li",{},"The second rule snapshots every protected branch, such as ",[14,172,173],{},"main"," or a release branch, so a merge request has a snapshot of its target branch to compare with.",[168,176,177,178,181,182,185],{},"Kubb names a branch snapshot after GitLab's branch slug, so ",[14,179,180],{},"release\u002F1.0"," and ",[14,183,184],{},"release-1.0"," share one. Give protected branches names that stay distinct as slugs.",[168,187,188,189,191,192,194],{},"Both rules need ",[14,190,30],{},", so a pipeline without the key, such as one for an unprotected branch or a fork, skips the job before ",[14,193,50],{}," runs.",[196,197,199,200,203,204,207,208,210,211,31],"blockquote",{"as":198},"important","By default, GitLab does not pass protected variables to merge request pipelines. In GitLab 18.1 or later, select ",[44,201,202],{},"Allow merge request pipelines to access protected variables and runners"," under ",[44,205,206],{},"Settings › CI\u002FCD › Variables",". The pipeline then gets ",[14,209,30],{}," only when the source and target branches are both protected and in the same project, and the user who starts it can merge into the target branch. See ",[19,212,214],{"href":213},"https:\u002F\u002Fdocs.gitlab.com\u002Fci\u002Fpipelines\u002Fmerge_request_pipelines\u002F#control-access-to-protected-variables-and-runners","merge request pipelines",[33,216,218],{"id":217},"post-the-result-as-a-merge-request-note","Post the result as a merge request note",[10,220,221,222,225],{},"Save the ",[14,223,224],{},"--json"," output and run this script. It updates one note per merge request and needs only Node:",[53,227,229],{"language":55,"filename":56,"code":228,"class":58}," script:\n - npm ci\n - npx kubb studio snapshot --json > snapshot.json\n - '[ -z \"$CI_MERGE_REQUEST_IID\" ] || [ -z \"$GITLAB_API_TOKEN\" ] || node scripts\u002Fkubb-note.mjs'",[14,230,231,75,240,75,246,75,255],{"class":61},[63,232,233,236,238],{"class":65,"style":66},[63,234,80],{"style":235},"color:#24292e;--hls-dark:#e1e4e8",[63,237,109],{"style":69},[63,239,74],{"style":73},[63,241,242,244],{"class":65,"style":66},[63,243,116],{"style":73},[63,245,50],{"style":89},[63,247,248,250,252],{"class":65,"style":66},[63,249,123],{"style":89},[63,251,126],{"style":73},[63,253,254],{"style":89},"npx kubb studio snapshot --json > snapshot.json",[63,256,257,259,261],{"class":65,"style":66},[63,258,123],{"style":89},[63,260,126],{"style":73},[63,262,263],{"style":89},"'[ -z \"$CI_MERGE_REQUEST_IID\" ] || [ -z \"$GITLAB_API_TOKEN\" ] || node scripts\u002Fkubb-note.mjs'",[196,265,266,281,304],{"as":198},[10,267,268,269,272,273,276,277,280],{},"Writing a note needs a project access token with the ",[14,270,271],{},"api"," scope, stored as ",[14,274,275],{},"GITLAB_API_TOKEN",". ",[14,278,279],{},"CI_JOB_TOKEN"," does not carry that scope.",[10,282,283,284,286,287,289,290,292,293,295,296,298,299,301,302,31],{},"Mark ",[14,285,275],{}," as ",[44,288,46],{}," too, like ",[14,291,30],{},". Masking only hides the value in job logs: any code the job runs can read it, including install scripts that ",[14,294,50],{}," runs. The ",[14,297,136],{}," skip the job without ",[14,300,30],{},", and the last script line skips the note without ",[14,303,275],{},[10,305,306],{},"Give the token the lowest role that can comment on merge requests, such as Reporter, and an expiry date.",[308,309,311],"code-collapse",{"name":310},"scripts\u002Fkubb-note.mjs",[53,312,315],{"language":313,"filename":310,"code":314,"class":58},"js","import { readFileSync } from 'node:fs'\n\nconst snapshot = JSON.parse(readFileSync('snapshot.json', 'utf8'))\nconst marker = '\u003C!-- kubb-snapshot -->'\nconst counts = (c) => `${c.added.length} added · ${c.changed.length} changed · ${c.removed.length} removed`\nconst lines = [marker, `Kubb snapshot: \\`npm i ${snapshot.url}\\``]\n\nconst { branchChanges: branch, changes } = snapshot\nif (branch) {\n if (branch.base) lines.push(`Changes against \\`${branch.branch}\\`: ${counts(branch)}`)\n else if (branch.baseFound) lines.push(`No snapshot of \\`${branch.branch}\\` for this package yet`)\n else lines.push(`No snapshot of \\`${branch.branch}\\` to compare with`)\n}\nif (changes?.base) lines.push(`Changes since ${changes.base.commit?.slice(0, 7) ?? changes.base.createdAt}: ${counts(changes)}`)\n\nconst { CI_API_V4_URL, CI_PROJECT_ID, CI_MERGE_REQUEST_IID, GITLAB_API_TOKEN } = process.env\nconst notes = `${CI_API_V4_URL}\u002Fprojects\u002F${CI_PROJECT_ID}\u002Fmerge_requests\u002F${CI_MERGE_REQUEST_IID}\u002Fnotes`\nconst headers = { 'PRIVATE-TOKEN': GITLAB_API_TOKEN, 'Content-Type': 'application\u002Fjson' }\nconst existing = (await (await fetch(`${notes}?per_page=100`, { headers })).json()).find((note) => note.body.startsWith(marker))\nconst response = await fetch(existing ? `${notes}\u002F${existing.id}` : notes, {\n method: existing ? 'PUT' : 'POST',\n headers,\n body: JSON.stringify({ body: lines.join('\\n\\n') }),\n})\nif (!response.ok) throw new Error(`GitLab answered ${response.status}`)",[14,316,318,75,338,75,340,75,380,75,392,75,472,75,516,75,518,75,543,75,555,75,619,75,667,75,703,75,707,75,798,75,800,75,836,75,874,75,904,75,989,75,1044,75,1068,75,1077,75,1121,75,1126],{"class":317},"language-js",[63,319,320,323,326,329,332,335],{"class":65,"style":66},[63,321,322],{"style":73},"import ",[63,324,325],{"style":69},"{ ",[63,327,328],{"style":235},"readFileSync ",[63,330,331],{"style":69},"} ",[63,333,334],{"style":73},"from ",[63,336,337],{"style":89},"'node:fs'",[63,339],{"class":65,"style":66},[63,341,342,345,348,351,354,356,360,363,366,368,371,374,377],{"class":65,"style":66},[63,343,344],{"style":73},"const ",[63,346,347],{"style":235},"snapshot ",[63,349,350],{"style":73},"= ",[63,352,353],{"style":69},"JSON",[63,355,31],{"style":73},[63,357,359],{"style":358},"color:#6f42c1;--hls-dark:#b392f0","parse",[63,361,362],{"style":69},"(",[63,364,365],{"style":358},"readFileSync",[63,367,362],{"style":69},[63,369,370],{"style":89},"'snapshot.json'",[63,372,373],{"style":73},", ",[63,375,376],{"style":89},"'utf8'",[63,378,379],{"style":69},"))",[63,381,382,384,387,389],{"class":65,"style":66},[63,383,344],{"style":73},[63,385,386],{"style":235},"marker ",[63,388,350],{"style":73},[63,390,391],{"style":89},"'\u003C!-- kubb-snapshot -->'",[63,393,394,396,399,401,403,406,409,412,415,418,420,422,425,427,430,433,436,438,440,442,445,447,449,451,454,456,458,460,463,465,467,469],{"class":65,"style":66},[63,395,344],{"style":73},[63,397,398],{"style":235},"counts ",[63,400,350],{"style":73},[63,402,362],{"style":69},[63,404,405],{"style":235},"c",[63,407,408],{"style":69},") ",[63,410,411],{"style":73},"=> ",[63,413,414],{"style":89},"`",[63,416,417],{"style":235},"${",[63,419,405],{"style":235},[63,421,31],{"style":73},[63,423,424],{"style":69},"added",[63,426,31],{"style":73},[63,428,429],{"style":69},"length",[63,431,432],{"style":235},"}",[63,434,435],{"style":89}," added · ",[63,437,417],{"style":235},[63,439,405],{"style":235},[63,441,31],{"style":73},[63,443,444],{"style":69},"changed",[63,446,31],{"style":73},[63,448,429],{"style":69},[63,450,432],{"style":235},[63,452,453],{"style":89}," changed · ",[63,455,417],{"style":235},[63,457,405],{"style":235},[63,459,31],{"style":73},[63,461,462],{"style":69},"removed",[63,464,31],{"style":73},[63,466,429],{"style":69},[63,468,432],{"style":235},[63,470,471],{"style":89}," removed`",[63,473,474,476,479,481,484,487,489,492,495,498,500,502,504,507,509,511,513],{"class":65,"style":66},[63,475,344],{"style":73},[63,477,478],{"style":235},"lines ",[63,480,350],{"style":73},[63,482,483],{"style":69},"[",[63,485,486],{"style":235},"marker",[63,488,373],{"style":73},[63,490,491],{"style":89},"`Kubb snapshot: ",[63,493,494],{"style":89},"\\`",[63,496,497],{"style":89},"npm i ",[63,499,417],{"style":235},[63,501,70],{"style":235},[63,503,31],{"style":73},[63,505,506],{"style":69},"url",[63,508,432],{"style":235},[63,510,494],{"style":89},[63,512,414],{"style":89},[63,514,515],{"style":69},"]",[63,517],{"class":65,"style":66},[63,519,520,522,524,527,529,532,534,537,539,541],{"class":65,"style":66},[63,521,344],{"style":73},[63,523,325],{"style":69},[63,525,526],{"style":69},"branchChanges",[63,528,86],{"style":73},[63,530,531],{"style":235},"branch",[63,533,373],{"style":73},[63,535,536],{"style":235},"changes ",[63,538,331],{"style":69},[63,540,350],{"style":73},[63,542,70],{"style":235},[63,544,545,548,550,552],{"class":65,"style":66},[63,546,547],{"style":73},"if ",[63,549,362],{"style":69},[63,551,531],{"style":235},[63,553,554],{"style":69},") {",[63,556,557,559,561,563,565,567,570,572,575,577,580,582,585,587,589,591,593,595,597,599,601,603,606,608,610,613,615,617],{"class":65,"style":66},[63,558,80],{"style":69},[63,560,547],{"style":73},[63,562,362],{"style":69},[63,564,531],{"style":235},[63,566,31],{"style":73},[63,568,569],{"style":69},"base",[63,571,408],{"style":69},[63,573,574],{"style":235},"lines",[63,576,31],{"style":73},[63,578,579],{"style":358},"push",[63,581,362],{"style":69},[63,583,584],{"style":89},"`Changes against ",[63,586,494],{"style":89},[63,588,417],{"style":235},[63,590,531],{"style":235},[63,592,31],{"style":73},[63,594,531],{"style":69},[63,596,432],{"style":235},[63,598,494],{"style":89},[63,600,86],{"style":89},[63,602,417],{"style":235},[63,604,605],{"style":358},"counts",[63,607,362],{"style":69},[63,609,531],{"style":235},[63,611,612],{"style":69},")",[63,614,432],{"style":235},[63,616,414],{"style":89},[63,618,612],{"style":69},[63,620,621,623,626,628,630,632,635,637,639,641,643,645,648,650,652,654,656,658,660,662,665],{"class":65,"style":66},[63,622,80],{"style":69},[63,624,625],{"style":73},"else if ",[63,627,362],{"style":69},[63,629,531],{"style":235},[63,631,31],{"style":73},[63,633,634],{"style":69},"baseFound",[63,636,408],{"style":69},[63,638,574],{"style":235},[63,640,31],{"style":73},[63,642,579],{"style":358},[63,644,362],{"style":69},[63,646,647],{"style":89},"`No snapshot of ",[63,649,494],{"style":89},[63,651,417],{"style":235},[63,653,531],{"style":235},[63,655,31],{"style":73},[63,657,531],{"style":69},[63,659,432],{"style":235},[63,661,494],{"style":89},[63,663,664],{"style":89}," for this package yet`",[63,666,612],{"style":69},[63,668,669,671,674,676,678,680,682,684,686,688,690,692,694,696,698,701],{"class":65,"style":66},[63,670,80],{"style":69},[63,672,673],{"style":73},"else ",[63,675,574],{"style":235},[63,677,31],{"style":73},[63,679,579],{"style":358},[63,681,362],{"style":69},[63,683,647],{"style":89},[63,685,494],{"style":89},[63,687,417],{"style":235},[63,689,531],{"style":235},[63,691,31],{"style":73},[63,693,531],{"style":69},[63,695,432],{"style":235},[63,697,494],{"style":89},[63,699,700],{"style":89}," to compare with`",[63,702,612],{"style":69},[63,704,705],{"class":65,"style":66},[63,706,432],{"style":69},[63,708,709,711,713,716,719,721,723,725,727,729,731,734,736,738,740,742,744,747,749,752,754,757,759,762,764,767,769,771,773,775,778,780,782,784,786,788,790,792,794,796],{"class":65,"style":66},[63,710,547],{"style":73},[63,712,362],{"style":69},[63,714,715],{"style":235},"changes",[63,717,718],{"style":73},"?.",[63,720,569],{"style":69},[63,722,408],{"style":69},[63,724,574],{"style":235},[63,726,31],{"style":73},[63,728,579],{"style":358},[63,730,362],{"style":69},[63,732,733],{"style":89},"`Changes since ",[63,735,417],{"style":235},[63,737,715],{"style":235},[63,739,31],{"style":73},[63,741,569],{"style":69},[63,743,31],{"style":73},[63,745,746],{"style":69},"commit",[63,748,718],{"style":73},[63,750,751],{"style":358},"slice",[63,753,362],{"style":69},[63,755,756],{"style":69},"0",[63,758,373],{"style":73},[63,760,761],{"style":69},"7",[63,763,408],{"style":69},[63,765,766],{"style":73},"?? ",[63,768,715],{"style":235},[63,770,31],{"style":73},[63,772,569],{"style":69},[63,774,31],{"style":73},[63,776,777],{"style":69},"createdAt",[63,779,432],{"style":235},[63,781,86],{"style":89},[63,783,417],{"style":235},[63,785,605],{"style":358},[63,787,362],{"style":69},[63,789,715],{"style":235},[63,791,612],{"style":69},[63,793,432],{"style":235},[63,795,414],{"style":89},[63,797,612],{"style":69},[63,799],{"class":65,"style":66},[63,801,802,804,806,809,811,814,816,819,821,824,826,828,831,833],{"class":65,"style":66},[63,803,344],{"style":73},[63,805,325],{"style":69},[63,807,808],{"style":69},"CI_API_V4_URL",[63,810,373],{"style":73},[63,812,813],{"style":69},"CI_PROJECT_ID",[63,815,373],{"style":73},[63,817,818],{"style":69},"CI_MERGE_REQUEST_IID",[63,820,373],{"style":73},[63,822,823],{"style":69},"GITLAB_API_TOKEN ",[63,825,331],{"style":69},[63,827,350],{"style":73},[63,829,830],{"style":235},"process",[63,832,31],{"style":73},[63,834,835],{"style":69},"env",[63,837,838,840,843,845,847,849,851,853,856,858,860,862,865,867,869,871],{"class":65,"style":66},[63,839,344],{"style":73},[63,841,842],{"style":235},"notes ",[63,844,350],{"style":73},[63,846,414],{"style":89},[63,848,417],{"style":235},[63,850,808],{"style":69},[63,852,432],{"style":235},[63,854,855],{"style":89},"\u002Fprojects\u002F",[63,857,417],{"style":235},[63,859,813],{"style":69},[63,861,432],{"style":235},[63,863,864],{"style":89},"\u002Fmerge_requests\u002F",[63,866,417],{"style":235},[63,868,818],{"style":69},[63,870,432],{"style":235},[63,872,873],{"style":89},"\u002Fnotes`",[63,875,876,878,881,883,885,888,890,892,894,897,899,902],{"class":65,"style":66},[63,877,344],{"style":73},[63,879,880],{"style":235},"headers ",[63,882,350],{"style":73},[63,884,325],{"style":69},[63,886,887],{"style":89},"'PRIVATE-TOKEN'",[63,889,86],{"style":73},[63,891,275],{"style":69},[63,893,373],{"style":73},[63,895,896],{"style":89},"'Content-Type'",[63,898,86],{"style":73},[63,900,901],{"style":89},"'application\u002Fjson' ",[63,903,432],{"style":69},[63,905,906,908,911,913,915,918,920,922,925,927,929,931,934,936,939,941,943,945,948,950,953,956,958,961,964,967,969,971,973,975,978,980,983,985,987],{"class":65,"style":66},[63,907,344],{"style":73},[63,909,910],{"style":235},"existing ",[63,912,350],{"style":73},[63,914,362],{"style":69},[63,916,917],{"style":73},"await ",[63,919,362],{"style":69},[63,921,917],{"style":73},[63,923,924],{"style":358},"fetch",[63,926,362],{"style":69},[63,928,414],{"style":89},[63,930,417],{"style":235},[63,932,933],{"style":235},"notes",[63,935,432],{"style":235},[63,937,938],{"style":89},"?per_page=100`",[63,940,373],{"style":73},[63,942,325],{"style":69},[63,944,880],{"style":235},[63,946,947],{"style":69},"}))",[63,949,31],{"style":73},[63,951,952],{"style":358},"json",[63,954,955],{"style":69},"())",[63,957,31],{"style":73},[63,959,960],{"style":358},"find",[63,962,963],{"style":69},"((",[63,965,966],{"style":235},"note",[63,968,408],{"style":69},[63,970,411],{"style":73},[63,972,966],{"style":235},[63,974,31],{"style":73},[63,976,977],{"style":69},"body",[63,979,31],{"style":73},[63,981,982],{"style":358},"startsWith",[63,984,362],{"style":69},[63,986,486],{"style":235},[63,988,379],{"style":69},[63,990,991,993,996,998,1000,1002,1004,1006,1009,1011,1013,1015,1017,1020,1022,1025,1027,1030,1032,1035,1037,1039,1041],{"class":65,"style":66},[63,992,344],{"style":73},[63,994,995],{"style":235},"response ",[63,997,350],{"style":73},[63,999,917],{"style":73},[63,1001,924],{"style":358},[63,1003,362],{"style":69},[63,1005,910],{"style":235},[63,1007,1008],{"style":73},"? ",[63,1010,414],{"style":89},[63,1012,417],{"style":235},[63,1014,933],{"style":235},[63,1016,432],{"style":235},[63,1018,1019],{"style":89},"\u002F",[63,1021,417],{"style":235},[63,1023,1024],{"style":235},"existing",[63,1026,31],{"style":73},[63,1028,1029],{"style":69},"id",[63,1031,432],{"style":235},[63,1033,1034],{"style":89},"` ",[63,1036,86],{"style":73},[63,1038,933],{"style":235},[63,1040,373],{"style":73},[63,1042,1043],{"style":69},"{",[63,1045,1046,1048,1051,1053,1055,1057,1060,1062,1065],{"class":65,"style":66},[63,1047,80],{"style":69},[63,1049,1050],{"style":69},"method",[63,1052,86],{"style":73},[63,1054,910],{"style":235},[63,1056,1008],{"style":73},[63,1058,1059],{"style":89},"'PUT' ",[63,1061,86],{"style":73},[63,1063,1064],{"style":89},"'POST'",[63,1066,1067],{"style":73},",",[63,1069,1070,1072,1075],{"class":65,"style":66},[63,1071,80],{"style":73},[63,1073,1074],{"style":235},"headers",[63,1076,1067],{"style":73},[63,1078,1079,1081,1083,1085,1087,1089,1092,1095,1097,1099,1101,1103,1106,1108,1111,1114,1116,1119],{"class":65,"style":66},[63,1080,80],{"style":73},[63,1082,977],{"style":69},[63,1084,86],{"style":73},[63,1086,353],{"style":69},[63,1088,31],{"style":73},[63,1090,1091],{"style":358},"stringify",[63,1093,1094],{"style":69},"({ ",[63,1096,977],{"style":69},[63,1098,86],{"style":73},[63,1100,574],{"style":235},[63,1102,31],{"style":73},[63,1104,1105],{"style":358},"join",[63,1107,362],{"style":69},[63,1109,1110],{"style":89},"'",[63,1112,1113],{"style":89},"\\n\\n",[63,1115,1110],{"style":89},[63,1117,1118],{"style":69},") })",[63,1120,1067],{"style":73},[63,1122,1123],{"class":65,"style":66},[63,1124,1125],{"style":69},"})",[63,1127,1128,1130,1132,1135,1138,1140,1143,1145,1148,1151,1154,1156,1159,1161,1163,1165,1168,1170,1172],{"class":65,"style":66},[63,1129,547],{"style":73},[63,1131,362],{"style":69},[63,1133,1134],{"style":73},"!",[63,1136,1137],{"style":235},"response",[63,1139,31],{"style":73},[63,1141,1142],{"style":69},"ok",[63,1144,408],{"style":69},[63,1146,1147],{"style":73},"throw ",[63,1149,1150],{"style":73},"new ",[63,1152,1153],{"style":358},"Error",[63,1155,362],{"style":69},[63,1157,1158],{"style":89},"`GitLab answered ",[63,1160,417],{"style":235},[63,1162,1137],{"style":235},[63,1164,31],{"style":73},[63,1166,1167],{"style":69},"status",[63,1169,432],{"style":235},[63,1171,414],{"style":89},[63,1173,612],{"style":69},[10,1175,1176,1177,181,1181,31],{},"To install a snapshot or read it in Studio, see ",[19,1178,1180],{"href":1179},"\u002Fdocs\u002F5.x\u002Fintegrations\u002Fci#review-the-snapshot","Review the snapshot",[19,1182,1184],{"href":1183},"\u002Fdocs\u002F5.x\u002Fintegrations\u002Fci#install-the-snapshot","Install the snapshot",{"title":1186,"searchDepth":1187,"depth":1187,"links":1188},"",5,[1189,1191],{"id":35,"depth":1190,"text":36},2,{"id":217,"depth":1190,"text":218},"Add a GitLab CI job that runs kubb studio snapshot on each merge request and compares the generated files with the target branch and the previous pipeline.","md",{"layout":1195,"title":5,"description":1192,"order":1196,"navigation":1197},"doc",4,{"title":1198,"icon":1199},"GitLab CI","i-simple-icons-gitlab",{"layout":1195},{"title":1198,"icon":1199},"\u002Fdocs\u002F5.x\u002Fintegrations\u002Fgitlab",{"title":5,"description":1192},{"loc":1202},"kubb-labs\u002Fkubb\u002Fdocs\u002F5.x\u002Fintegrations\u002Fgitlab.md","docs\u002F5.x\u002Fintegrations\u002Fgitlab","aJHakEDRzeDmQygoVi8FDytsv2nSlzib-UEIBrzlYF8",1795727673959,"1b64b1eb-29b7-4f90-ad41-6f24721e1669"]