Hello everyone! My name is Artyom Peskishev, I am an iOS developer in Avito. I want to tell you how we started a backend-driven script for publishing new ads in our mobile applications.
Let’s see what step-by-step scripts are in applications and what problems we had with the script for placing an ad. The article is about a tool we developed to solve these problems and the results of its implementation.

Backend-driven ui
Backend-driven UI — , , , , , .
Backend-driven UI , . , . , . . , .
backend-driven — backend-driven UI.
— , . — . : , Wi-Fi, Apple ID. .

— . , MyFitnessPal, . , .

. «». . , . , , , « ». .

« ». , , . , . , « ».
. . , , .
, . , . , . , QA-. .
, . , , . , . , .
, , , , . . - . . iOS, Android, Desktop .

, , . .
:
- .
- .
-
«». :
- Select .
- Input .
- Address .
- Photos .
- Bool .
. , , . , , . , , .
«» , . .
. — , .
, — , . . , , , . , , . — -.
— . - . select. . , . , , .
— . , .
— . , . , , . .
. , . « », . , . , «».
, « » . . .
«». VIN, VIN . 18 .
, , , , , . - , , . , .
, :
- , ?
- ? , . , — , , . .
- ? , . .
, . , -. .
:
- Pretend, , .
- . , .
- . .
, backend-driven UI , .
: , .
— UI- . , , . . : , , .
"steps": [{
"id": 1133,
"title": " ",
"fields": [],
"type": "wizard"
}, {
"id": 1169,
"title": " ",
"fields": [],
"type": "request",
"subtype": "steps",
}, {
"id": 1168,
"title": "",
"fields": [499],
"type": "params"
}, {
"id": 1134,
"title": "VIN ",
"fields": [838],
"type": "vin"
}, {
"id": 1163,
"title": " ",
"fields": [549, 498, ...],
"type": "params"
},
{...}]
. , . , .
, . , «», . , , . , , "value" . — iOS, Android .
.

DynamicPublish , , , .
, — . DataService, , - -, . .
— StepHandler. , , .
StepHandler, . , Wizard — StepHandler, . Steps -. Select . Params .
. -, . . , , «» .
StepHandler. StepHandler - , . .
, «», , . , «».
. StepHandler . - — , , . n , — , .
. , , , . . - , .
. . — , , . , , , , , . . .
42 , . .

— . , . , , .
. /- .
. , .
. . , — . , , , .
. , . — . , MVP , . , , .