001// Generated by delombok at Thu Aug 13 13:56:44 UTC 2026
002/*
003 * Copyright (c) 2010-2026 Mark Allen, Norbert Bartels.
004 *
005 * Permission is hereby granted, free of charge, to any person obtaining a copy
006 * of this software and associated documentation files (the "Software"), to deal
007 * in the Software without restriction, including without limitation the rights
008 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
009 * copies of the Software, and to permit persons to whom the Software is
010 * furnished to do so, subject to the following conditions:
011 *
012 * The above copyright notice and this permission notice shall be included in
013 * all copies or substantial portions of the Software.
014 *
015 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
016 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
017 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
018 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
019 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
020 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
021 * THE SOFTWARE.
022 */
023package com.restfb.types;
024
025import java.util.Date;
026import com.restfb.Facebook;
027import com.restfb.types.features.HasCreatedTime;
028import com.restfb.types.features.HasFrom;
029import com.restfb.types.features.HasMessage;
030
031/**
032 * Represents the <a href="https://developers.facebook.com/docs/reference/api/user/#apprequests" >App Request Graph API
033 * type</a>.
034 *
035 * @author <a href="http://restfb.com">Mark Allen</a>
036 * @since 1.6.10
037 */
038public class AppRequest extends FacebookType implements HasCreatedTime, HasFrom, HasMessage {
039  /**
040   * Request action type for structured request
041   */
042  @Facebook("action_type")
043  private String actionType;
044  /**
045   * App associated with the request.
046   */
047  @Facebook
048  private Application application;
049  /**
050   * Optional data passed with the request for tracking purposes
051   */
052  @Facebook
053  private String data;
054  /**
055   * The recipient user associated with the request.
056   */
057  @Facebook
058  private NamedFacebookType to;
059  /**
060   * The sender user associated with the request.
061   */
062  @Facebook
063  private NamedFacebookType from;
064  /**
065   * A string describing the request.
066   */
067  @Facebook
068  private String message;
069  /**
070   * Timestamp when the request was created.
071   */
072  @Facebook("created_time")
073  private Date createdTime;
074  private static final long serialVersionUID = 1L;
075
076
077  /**
078   * Represents the <a href="http://developers.facebook.com/docs/reference/api/page">Cover Graph API type</a>.
079   *
080   * @author <a href="http://restfb.com">Mark Allen</a>
081   * @since 1.6.10
082   */
083  public static class Application extends NamedFacebookType {
084    /**
085     * The application's canvas name.
086     */
087    @Facebook("canvas_name")
088    private String canvasName;
089    /**
090     * The application's namespace.
091     */
092    @Facebook
093    private String namespace;
094    private static final long serialVersionUID = 1L;
095
096    /**
097     * The application's canvas name.
098     *
099     * @return The application's canvas name.
100     */
101    @java.lang.SuppressWarnings("all")
102    @lombok.Generated
103    public String getCanvasName() {
104      return this.canvasName;
105    }
106
107    /**
108     * The application's canvas name.
109     */
110    @java.lang.SuppressWarnings("all")
111    @lombok.Generated
112    public void setCanvasName(final String canvasName) {
113      this.canvasName = canvasName;
114    }
115
116    /**
117     * The application's namespace.
118     *
119     * @return The application's namespace.
120     */
121    @java.lang.SuppressWarnings("all")
122    @lombok.Generated
123    public String getNamespace() {
124      return this.namespace;
125    }
126
127    /**
128     * The application's namespace.
129     */
130    @java.lang.SuppressWarnings("all")
131    @lombok.Generated
132    public void setNamespace(final String namespace) {
133      this.namespace = namespace;
134    }
135  }
136
137  /**
138   * Request action type for structured request
139   *
140   * @return Request action type for structured request
141   */
142  @java.lang.SuppressWarnings("all")
143  @lombok.Generated
144  public String getActionType() {
145    return this.actionType;
146  }
147
148  /**
149   * Request action type for structured request
150   */
151  @java.lang.SuppressWarnings("all")
152  @lombok.Generated
153  public void setActionType(final String actionType) {
154    this.actionType = actionType;
155  }
156
157  /**
158   * App associated with the request.
159   *
160   * @return App associated with the request.
161   */
162  @java.lang.SuppressWarnings("all")
163  @lombok.Generated
164  public Application getApplication() {
165    return this.application;
166  }
167
168  /**
169   * App associated with the request.
170   */
171  @java.lang.SuppressWarnings("all")
172  @lombok.Generated
173  public void setApplication(final Application application) {
174    this.application = application;
175  }
176
177  /**
178   * Optional data passed with the request for tracking purposes
179   *
180   * @return Optional data passed with the request for tracking purposes
181   */
182  @java.lang.SuppressWarnings("all")
183  @lombok.Generated
184  public String getData() {
185    return this.data;
186  }
187
188  /**
189   * Optional data passed with the request for tracking purposes
190   */
191  @java.lang.SuppressWarnings("all")
192  @lombok.Generated
193  public void setData(final String data) {
194    this.data = data;
195  }
196
197  /**
198   * The recipient user associated with the request.
199   *
200   * @return The recipient user associated with the request.
201   */
202  @java.lang.SuppressWarnings("all")
203  @lombok.Generated
204  public NamedFacebookType getTo() {
205    return this.to;
206  }
207
208  /**
209   * The recipient user associated with the request.
210   */
211  @java.lang.SuppressWarnings("all")
212  @lombok.Generated
213  public void setTo(final NamedFacebookType to) {
214    this.to = to;
215  }
216
217  /**
218   * The sender user associated with the request.
219   *
220   * @return The sender user associated with the request.
221   */
222  @Override
223  @java.lang.SuppressWarnings("all")
224  @lombok.Generated
225  public NamedFacebookType getFrom() {
226    return this.from;
227  }
228
229  /**
230   * The sender user associated with the request.
231   */
232  @java.lang.SuppressWarnings("all")
233  @lombok.Generated
234  public void setFrom(final NamedFacebookType from) {
235    this.from = from;
236  }
237
238  /**
239   * A string describing the request.
240   *
241   * @return A string describing the request.
242   */
243  @Override
244  @java.lang.SuppressWarnings("all")
245  @lombok.Generated
246  public String getMessage() {
247    return this.message;
248  }
249
250  /**
251   * A string describing the request.
252   */
253  @java.lang.SuppressWarnings("all")
254  @lombok.Generated
255  public void setMessage(final String message) {
256    this.message = message;
257  }
258
259  /**
260   * Timestamp when the request was created.
261   *
262   * @return Timestamp when the request was created.
263   */
264  @Override
265  @java.lang.SuppressWarnings("all")
266  @lombok.Generated
267  public Date getCreatedTime() {
268    return this.createdTime;
269  }
270
271  /**
272   * Timestamp when the request was created.
273   */
274  @java.lang.SuppressWarnings("all")
275  @lombok.Generated
276  public void setCreatedTime(final Date createdTime) {
277    this.createdTime = createdTime;
278  }
279}