@@ -514,6 +514,51 @@ class CurrentUserManager(GetWithoutIdMixin, RESTManager):
514
514
_obj_cls = CurrentUser
515
515
516
516
517
+ class ApplicationAppearance (SaveMixin , RESTObject ):
518
+ _id_attr = None
519
+
520
+
521
+ class ApplicationAppearanceManager (GetWithoutIdMixin , UpdateMixin , RESTManager ):
522
+ _path = "/application/appearance"
523
+ _obj_cls = ApplicationAppearance
524
+ _update_attrs = (
525
+ tuple (),
526
+ (
527
+ "title" ,
528
+ "description" ,
529
+ "logo" ,
530
+ "header_logo" ,
531
+ "favicon" ,
532
+ "new_project_guidelines" ,
533
+ "header_message" ,
534
+ "footer_message" ,
535
+ "message_background_color" ,
536
+ "message_font_color" ,
537
+ "email_header_and_footer_enabled" ,
538
+ ),
539
+ )
540
+
541
+ @exc .on_http_error (exc .GitlabUpdateError )
542
+ def update (self , id = None , new_data = None , ** kwargs ):
543
+ """Update an object on the server.
544
+
545
+ Args:
546
+ id: ID of the object to update (can be None if not required)
547
+ new_data: the update data for the object
548
+ **kwargs: Extra options to send to the server (e.g. sudo)
549
+
550
+ Returns:
551
+ dict: The new object data (*not* a RESTObject)
552
+
553
+ Raises:
554
+ GitlabAuthenticationError: If authentication is not correct
555
+ GitlabUpdateError: If the server cannot perform the request
556
+ """
557
+ new_data = new_data or {}
558
+ data = new_data .copy ()
559
+ super (ApplicationAppearanceManager , self ).update (id , data , ** kwargs )
560
+
561
+
517
562
class ApplicationSettings (SaveMixin , RESTObject ):
518
563
_id_attr = None
519
564
0 commit comments