feat:version

This commit is contained in:
2026-06-24 18:10:04 +03:30
parent a63cefb80b
commit b1f1fb33c2
7 changed files with 140 additions and 0 deletions
+19
View File
@@ -0,0 +1,19 @@
meta {
name: delete version
type: http
seq: 6
}
delete {
url: {{baseUrl}}/versions/:id
body: none
auth: inherit
}
params:path {
id: 1
}
settings {
encodeUrl: true
}
+8
View File
@@ -0,0 +1,8 @@
meta {
name: version
seq: 21
}
auth {
mode: inherit
}
+19
View File
@@ -0,0 +1,19 @@
meta {
name: get versions
type: http
seq: 2
}
get {
url: {{baseUrl}}/versions
body: none
auth: inherit
}
settings {
encodeUrl: true
}
docs {
Admin: all versions, highest version_code first.
}
+19
View File
@@ -0,0 +1,19 @@
meta {
name: latest version
type: http
seq: 1
}
get {
url: {{baseUrl}}/versions/latest
body: none
auth: inherit
}
settings {
encodeUrl: true
}
docs {
App update check: returns the newest version (highest version_code), or null.
}
+19
View File
@@ -0,0 +1,19 @@
meta {
name: show version
type: http
seq: 4
}
get {
url: {{baseUrl}}/versions/:id
body: none
auth: inherit
}
params:path {
id: 1
}
settings {
encodeUrl: true
}
+26
View File
@@ -0,0 +1,26 @@
meta {
name: store version
type: http
seq: 3
}
post {
url: {{baseUrl}}/versions
body: multipartForm
auth: inherit
}
body:multipart-form {
title: نسخه ۱.۲.۰
description: توضیح تغییرات نسخه
version_name: 1.2.0
version_code: 42
link: https://example.com/app.apk
~image: @file()
~image_id: 1
}
settings {
encodeUrl: true
timeout: 0
}
+30
View File
@@ -0,0 +1,30 @@
meta {
name: update version
type: http
seq: 5
}
post {
url: {{baseUrl}}/versions/:id
body: multipartForm
auth: inherit
}
params:path {
id: 1
}
body:multipart-form {
title: نسخه جدید
description: توضیح جدید
version_name: 1.3.0
version_code: 43
link: https://example.com/app.apk
~image: @file()
~image_id: 1
}
settings {
encodeUrl: true
timeout: 0
}