-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathBitlinkUpdateBody.ts
More file actions
113 lines (102 loc) · 3 KB
/
Copy pathBitlinkUpdateBody.ts
File metadata and controls
113 lines (102 loc) · 3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
/* tslint:disable */
/* eslint-disable */
/**
* Bitly API
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 4.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import { mapValues } from '../runtime';
import type { DeeplinkRule } from './DeeplinkRule';
import {
DeeplinkRuleFromJSON,
DeeplinkRuleFromJSONTyped,
DeeplinkRuleToJSON,
DeeplinkRuleToJSONTyped,
} from './DeeplinkRule';
/**
*
* @export
* @interface BitlinkUpdateBody
*/
export interface BitlinkUpdateBody {
/**
*
* @type {string}
* @memberof BitlinkUpdateBody
*/
title?: string;
/**
*
* @type {boolean}
* @memberof BitlinkUpdateBody
*/
archived?: boolean;
/**
*
* @type {Array<string>}
* @memberof BitlinkUpdateBody
*/
tags?: Array<string>;
/**
*
* @type {Array<DeeplinkRule>}
* @memberof BitlinkUpdateBody
*/
deeplinks?: Array<DeeplinkRule>;
/**
*
* @type {string}
* @memberof BitlinkUpdateBody
*/
long_url?: string;
/**
* Coming soon
* @type {string}
* @memberof BitlinkUpdateBody
*/
expiration_at?: string;
}
/**
* Check if a given object implements the BitlinkUpdateBody interface.
*/
export function instanceOfBitlinkUpdateBody(value: object): value is BitlinkUpdateBody {
return true;
}
export function BitlinkUpdateBodyFromJSON(json: any): BitlinkUpdateBody {
return BitlinkUpdateBodyFromJSONTyped(json, false);
}
export function BitlinkUpdateBodyFromJSONTyped(json: any, ignoreDiscriminator: boolean): BitlinkUpdateBody {
if (json == null) {
return json;
}
return {
'title': json['title'] == null ? undefined : json['title'],
'archived': json['archived'] == null ? undefined : json['archived'],
'tags': json['tags'] == null ? undefined : json['tags'],
'deeplinks': json['deeplinks'] == null ? undefined : ((json['deeplinks'] as Array<any>).map(DeeplinkRuleFromJSON)),
'long_url': json['long_url'] == null ? undefined : json['long_url'],
'expiration_at': json['expiration_at'] == null ? undefined : json['expiration_at'],
};
}
export function BitlinkUpdateBodyToJSON(json: any): BitlinkUpdateBody {
return BitlinkUpdateBodyToJSONTyped(json, false);
}
export function BitlinkUpdateBodyToJSONTyped(value?: BitlinkUpdateBody | null, ignoreDiscriminator: boolean = false): any {
if (value == null) {
return value;
}
return {
'title': value['title'],
'archived': value['archived'],
'tags': value['tags'],
'deeplinks': value['deeplinks'] == null ? undefined : ((value['deeplinks'] as Array<any>).map(DeeplinkRuleToJSON)),
'long_url': value['long_url'],
'expiration_at': value['expiration_at'],
};
}