Skip to main content
Glama
devhub

DevHub CMS MCP

Official
by devhub

update_hours

Modify business hours for a DevHub location by specifying time ranges for each day, including multiple intervals for breaks and marking days as closed.

Instructions

Update the hours of operation for a DevHub location

Send a list of items representing days of the week

Except for the special case formatting, this object is a list of 7 items which represent each day.

Each day can can have one-four time ranges. For example, two time ranges denotes a "lunch-break". No time ranges denotes closed.

Examples:
9am-5pm [["09:00:00", "17:00:00"]]
9am-12pm and 1pm-5pm [["09:00:00", "12:00:00"], ["13:00:00", "17:00:00"]]
Closed - an empty list []

Args:
    location_id: DevHub Location ID
    new_hours: Structured format of the new hours
    hours_type: Defaults to 'primary' unless the user specifies a different type

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
location_idYes
new_hoursYes
hours_typeNoprimary

Implementation Reference

  • The update_hours tool handler: decorated with @mcp.tool() for MCP registration, includes input schema in docstring and parameters, executes API PUT request to update location hours in DevHub CMS.
    @mcp.tool()
    def update_hours(location_id: int, new_hours: list, hours_type: str = 'primary') -> str:
        """Update the hours of operation for a DevHub location
    
        Send a list of items representing days of the week
    
        Except for the special case formatting, this object is a list of 7 items which represent each day.
    
        Each day can can have one-four time ranges. For example, two time ranges denotes a "lunch-break". No time ranges denotes closed.
    
        Examples:
        9am-5pm [["09:00:00", "17:00:00"]]
        9am-12pm and 1pm-5pm [["09:00:00", "12:00:00"], ["13:00:00", "17:00:00"]]
        Closed - an empty list []
    
        Args:
            location_id: DevHub Location ID
            new_hours: Structured format of the new hours
            hours_type: Defaults to 'primary' unless the user specifies a different type
        """
        client, base_url = get_client()
        r = client.put(
            '{}locations/{}/'.format(base_url, location_id),
            json={
                'hours': [
                    {
                        'type': hours_type,
                        'hours': new_hours,
                    }
                ]
            },
        )
        content = json.loads(r.content)
        return 'Updated successfully'
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden. It clearly indicates this is a mutation tool ('Update'), describes the data structure (7 items representing days, 0-4 time ranges), and provides formatting examples. However, it lacks information about permissions, side effects, error conditions, or what happens to existing hours not mentioned.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is appropriately sized and well-structured: it starts with the core purpose, explains the data format, provides concrete examples, and lists parameters with explanations. Every sentence adds value, though the parameter explanations could be slightly more integrated with the initial description.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a mutation tool with no annotations and no output schema, the description does a good job explaining parameters and data format. However, it lacks information about what the tool returns, error handling, authentication requirements, or how changes affect existing data. The examples help but don't fully compensate for missing behavioral context.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 0% schema description coverage, the description fully compensates by explaining all three parameters: 'location_id' identifies the target, 'new_hours' is described in detail with structure and examples, and 'hours_type' is explained with its default value and optional nature. The description adds substantial meaning beyond the bare schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the specific action ('Update'), resource ('hours of operation for a DevHub location'), and scope (days of the week with time ranges). It distinguishes from sibling tools like 'get_hours_of_operation' by focusing on modification rather than retrieval.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage when updating hours for a DevHub location, but provides no explicit guidance on when to use this tool versus alternatives like 'get_hours_of_operation' or other update tools. No prerequisites, exclusions, or comparison to siblings are mentioned.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/devhub/devhub-cms-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server