|
2932 | 2932 | "content": { |
2933 | 2933 | "multipart/form-data": { |
2934 | 2934 | "schema": { |
2935 | | - "$ref": "#/components/schemas/CreateTemplateRequest" |
| 2935 | + "$ref": "#/components/schemas/UpdateTemplateRequest" |
2936 | 2936 | } |
2937 | 2937 | } |
2938 | 2938 | } |
|
3035 | 3035 | } |
3036 | 3036 | } |
3037 | 3037 | }, |
| 3038 | + "put": { |
| 3039 | + "tags": [ |
| 3040 | + "templates" |
| 3041 | + ], |
| 3042 | + "summary": "Update template.", |
| 3043 | + "description": "🚧 **Status: Beta** – This method is under development. Avoid using in production. Returns a JSON response of updated template.", |
| 3044 | + "operationId": "a73b9801869083ca7a9739aed68d1b92", |
| 3045 | + "parameters": [ |
| 3046 | + { |
| 3047 | + "name": "php-auth-pw", |
| 3048 | + "in": "header", |
| 3049 | + "description": "Session key obtained from login", |
| 3050 | + "required": true, |
| 3051 | + "schema": { |
| 3052 | + "type": "string" |
| 3053 | + } |
| 3054 | + } |
| 3055 | + ], |
| 3056 | + "requestBody": { |
| 3057 | + "description": "Pass session credentials", |
| 3058 | + "required": true, |
| 3059 | + "content": { |
| 3060 | + "multipart/form-data": { |
| 3061 | + "schema": { |
| 3062 | + "$ref": "#/components/schemas/CreateTemplateRequest" |
| 3063 | + } |
| 3064 | + } |
| 3065 | + } |
| 3066 | + }, |
| 3067 | + "responses": { |
| 3068 | + "201": { |
| 3069 | + "description": "Success", |
| 3070 | + "content": { |
| 3071 | + "application/json": { |
| 3072 | + "schema": { |
| 3073 | + "type": "array", |
| 3074 | + "items": { |
| 3075 | + "$ref": "#/components/schemas/Template" |
| 3076 | + } |
| 3077 | + } |
| 3078 | + } |
| 3079 | + } |
| 3080 | + }, |
| 3081 | + "403": { |
| 3082 | + "description": "Failure", |
| 3083 | + "content": { |
| 3084 | + "application/json": { |
| 3085 | + "schema": { |
| 3086 | + "$ref": "#/components/schemas/UnauthorizedResponse" |
| 3087 | + } |
| 3088 | + } |
| 3089 | + } |
| 3090 | + }, |
| 3091 | + "422": { |
| 3092 | + "description": "Failure", |
| 3093 | + "content": { |
| 3094 | + "application/json": { |
| 3095 | + "schema": { |
| 3096 | + "$ref": "#/components/schemas/ValidationErrorResponse" |
| 3097 | + } |
| 3098 | + } |
| 3099 | + } |
| 3100 | + } |
| 3101 | + } |
| 3102 | + }, |
3038 | 3103 | "delete": { |
3039 | 3104 | "tags": [ |
3040 | 3105 | "templates" |
|
7038 | 7103 | }, |
7039 | 7104 | "type": "object" |
7040 | 7105 | }, |
| 7106 | + "UpdateTemplateRequest": { |
| 7107 | + "required": [ |
| 7108 | + "title" |
| 7109 | + ], |
| 7110 | + "properties": { |
| 7111 | + "title": { |
| 7112 | + "type": "string", |
| 7113 | + "example": "Newsletter Template" |
| 7114 | + }, |
| 7115 | + "content": { |
| 7116 | + "type": "string", |
| 7117 | + "example": "<html><body>[CONTENT]</body></html>", |
| 7118 | + "nullable": true |
| 7119 | + }, |
| 7120 | + "text": { |
| 7121 | + "type": "string", |
| 7122 | + "example": "[CONTENT]" |
| 7123 | + }, |
| 7124 | + "file": { |
| 7125 | + "description": "Optional file upload for HTML content", |
| 7126 | + "type": "string", |
| 7127 | + "format": "binary" |
| 7128 | + }, |
| 7129 | + "check_links": { |
| 7130 | + "description": "Check that all links have full URLs", |
| 7131 | + "type": "boolean", |
| 7132 | + "example": true |
| 7133 | + }, |
| 7134 | + "check_images": { |
| 7135 | + "description": "Check that all images have full URLs", |
| 7136 | + "type": "boolean", |
| 7137 | + "example": false |
| 7138 | + }, |
| 7139 | + "check_external_images": { |
| 7140 | + "description": "Check that all external images exist", |
| 7141 | + "type": "boolean", |
| 7142 | + "example": true |
| 7143 | + } |
| 7144 | + }, |
| 7145 | + "type": "object" |
| 7146 | + }, |
7041 | 7147 | "BounceRegex": { |
7042 | 7148 | "properties": { |
7043 | 7149 | "id": { |
|
0 commit comments