ory_client/models/normalized_project_revision_hook.rs
1/*
2 * Ory APIs
3 *
4 * # Introduction Documentation for all public and administrative Ory APIs. Administrative APIs can only be accessed with a valid Personal Access Token. Public APIs are mostly used in browsers. ## SDKs This document describes the APIs available in the Ory Network. The APIs are available as SDKs for the following languages: | Language | Download SDK | Documentation | | -------------- | ---------------------------------------------------------------- | ------------------------------------------------------------------------------------ | | Dart | [pub.dev](https://pub.dev/packages/ory_client) | [README](https://github.com/ory/sdk/blob/master/clients/client/dart/README.md) | | .NET | [nuget.org](https://www.nuget.org/packages/Ory.Client/) | [README](https://github.com/ory/sdk/blob/master/clients/client/dotnet/README.md) | | Elixir | [hex.pm](https://hex.pm/packages/ory_client) | [README](https://github.com/ory/sdk/blob/master/clients/client/elixir/README.md) | | Go | [github.com](https://github.com/ory/client-go) | [README](https://github.com/ory/sdk/blob/master/clients/client/go/README.md) | | Java | [maven.org](https://search.maven.org/artifact/sh.ory/ory-client) | [README](https://github.com/ory/sdk/blob/master/clients/client/java/README.md) | | JavaScript | [npmjs.com](https://www.npmjs.com/package/@ory/client) | [README](https://github.com/ory/sdk/blob/master/clients/client/typescript/README.md) | | JavaScript (With fetch) | [npmjs.com](https://www.npmjs.com/package/@ory/client-fetch) | [README](https://github.com/ory/sdk/blob/master/clients/client/typescript-fetch/README.md) | | PHP | [packagist.org](https://packagist.org/packages/ory/client) | [README](https://github.com/ory/sdk/blob/master/clients/client/php/README.md) | | Python | [pypi.org](https://pypi.org/project/ory-client/) | [README](https://github.com/ory/sdk/blob/master/clients/client/python/README.md) | | Ruby | [rubygems.org](https://rubygems.org/gems/ory-client) | [README](https://github.com/ory/sdk/blob/master/clients/client/ruby/README.md) | | Rust | [crates.io](https://crates.io/crates/ory-client) | [README](https://github.com/ory/sdk/blob/master/clients/client/rust/README.md) |
5 *
6 * The version of the OpenAPI document: v1.22.4
7 * Contact: support@ory.sh
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct NormalizedProjectRevisionHook {
16 /// The Hooks Config Key
17 #[serde(rename = "config_key")]
18 pub config_key: String,
19 /// The Project's Revision Creation Date
20 #[serde(rename = "created_at", skip_serializing_if = "Option::is_none")]
21 pub created_at: Option<String>,
22 /// The Hook Type
23 #[serde(rename = "hook")]
24 pub hook: String,
25 /// ID of the entry
26 #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
27 pub id: Option<String>,
28 /// The Revision's ID this schema belongs to
29 #[serde(rename = "project_revision_id", skip_serializing_if = "Option::is_none")]
30 pub project_revision_id: Option<String>,
31 /// Last Time Project's Revision was Updated
32 #[serde(rename = "updated_at", skip_serializing_if = "Option::is_none")]
33 pub updated_at: Option<String>,
34 /// Whether to send the API Key in the HTTP Header or as a HTTP Cookie
35 #[serde(rename = "web_hook_config_auth_api_key_in", skip_serializing_if = "Option::is_none")]
36 pub web_hook_config_auth_api_key_in: Option<String>,
37 /// The name of the api key
38 #[serde(rename = "web_hook_config_auth_api_key_name", skip_serializing_if = "Option::is_none")]
39 pub web_hook_config_auth_api_key_name: Option<String>,
40 /// The value of the api key
41 #[serde(rename = "web_hook_config_auth_api_key_value", skip_serializing_if = "Option::is_none")]
42 pub web_hook_config_auth_api_key_value: Option<String>,
43 /// The password to be sent in the HTTP Basic Auth Header
44 #[serde(rename = "web_hook_config_auth_basic_auth_password", skip_serializing_if = "Option::is_none")]
45 pub web_hook_config_auth_basic_auth_password: Option<String>,
46 /// The username to be sent in the HTTP Basic Auth Header
47 #[serde(rename = "web_hook_config_auth_basic_auth_user", skip_serializing_if = "Option::is_none")]
48 pub web_hook_config_auth_basic_auth_user: Option<String>,
49 /// HTTP Auth Method to use for the Web-Hook
50 #[serde(rename = "web_hook_config_auth_type", skip_serializing_if = "Option::is_none")]
51 pub web_hook_config_auth_type: Option<String>,
52 /// URI pointing to the JsonNet template used for Web-Hook payload generation. Only used for those HTTP methods, which support HTTP body payloads.
53 #[serde(rename = "web_hook_config_body", skip_serializing_if = "Option::is_none")]
54 pub web_hook_config_body: Option<String>,
55 /// If enabled allows the web hook to interrupt / abort the self-service flow. It only applies to certain flows (registration/verification/login/settings) and requires a valid response format.
56 #[serde(rename = "web_hook_config_can_interrupt", skip_serializing_if = "Option::is_none")]
57 pub web_hook_config_can_interrupt: Option<bool>,
58 /// The HTTP method to use (GET, POST, etc) for the Web-Hook
59 #[serde(rename = "web_hook_config_method", skip_serializing_if = "Option::is_none")]
60 pub web_hook_config_method: Option<String>,
61 /// Whether to ignore the Web Hook response
62 #[serde(rename = "web_hook_config_response_ignore", skip_serializing_if = "Option::is_none")]
63 pub web_hook_config_response_ignore: Option<bool>,
64 /// Whether to parse the Web Hook response
65 #[serde(rename = "web_hook_config_response_parse", skip_serializing_if = "Option::is_none")]
66 pub web_hook_config_response_parse: Option<bool>,
67 /// The URL the Web-Hook should call
68 #[serde(rename = "web_hook_config_url", skip_serializing_if = "Option::is_none")]
69 pub web_hook_config_url: Option<String>,
70}
71
72impl NormalizedProjectRevisionHook {
73 pub fn new(config_key: String, hook: String) -> NormalizedProjectRevisionHook {
74 NormalizedProjectRevisionHook {
75 config_key,
76 created_at: None,
77 hook,
78 id: None,
79 project_revision_id: None,
80 updated_at: None,
81 web_hook_config_auth_api_key_in: None,
82 web_hook_config_auth_api_key_name: None,
83 web_hook_config_auth_api_key_value: None,
84 web_hook_config_auth_basic_auth_password: None,
85 web_hook_config_auth_basic_auth_user: None,
86 web_hook_config_auth_type: None,
87 web_hook_config_body: None,
88 web_hook_config_can_interrupt: None,
89 web_hook_config_method: None,
90 web_hook_config_response_ignore: None,
91 web_hook_config_response_parse: None,
92 web_hook_config_url: None,
93 }
94 }
95}
96