aboutsummaryrefslogtreecommitdiffstats
path: root/github3/models/orgs.py
blob: 5e66c3502130ae7d37b8b9b7d90d100bb4edc520 (plain) (blame)
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
#!/usr/bin/env python
# -*- encoding: utf-8 -*-
#
# author: David Medina

from .base import BaseResource
from .user import Plan

class Org(BaseResource):
    """Github Organization object model."""

    @classmethod
    def idl(self):
        return {
            'strs': ['login', 'url', 'avatar_url', 'name', 'company', 'blog',
                     'location', 'email', 'html_url', 'type', 'billing_email'],
            'ints': ['id', 'public_repos', 'public_gists', 'followers',
                     'following', 'total_private_repos', 'owned_private_repos',
                     'private_gists', 'disk_usage', 'collaborators'],
            'dates': ['created_at'],
            'maps': {'plan': Plan}
        }

    def __repr__(self):
        return '<Org %s>' % self.login