get_journal_details
Retrieve detailed journal information from Oracle EPM Cloud FCCS by specifying journal label, with options to filter by scenario, year, period, and include line items.
Instructions
Get detailed information about a specific journal / Obter detalhes de um diario
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| journal_label | Yes | The journal label | |
| scenario | No | Filter by scenario | |
| year | No | Filter by year | |
| period | No | Filter by period | |
| line_items | No | Include line items (default: true) |
Implementation Reference
- fccs_agent/tools/journals.py:63-93 (handler)The main handler function for the 'get_journal_details' tool. It processes input parameters, constructs optional filters, calls the underlying FCCS client method, and returns formatted results.async def get_journal_details( journal_label: str, scenario: Optional[str] = None, year: Optional[str] = None, period: Optional[str] = None, line_items: bool = True ) -> dict[str, Any]: """Get detailed information about a specific journal / Obter detalhes de um diario. Args: journal_label: The journal label. scenario: Filter by scenario. year: Filter by year. period: Filter by period. line_items: Include line items (default: true). Returns: dict: Journal details. """ filters = {} if scenario: filters["scenario"] = scenario if year: filters["year"] = year if period: filters["period"] = period details = await _client.get_journal_details( _app_name, journal_label, filters if filters else None, line_items ) return {"status": "success", "data": details}
- fccs_agent/tools/journals.py:187-201 (schema)The input schema definition for the 'get_journal_details' tool, specifying parameters, types, descriptions, and required fields.{ "name": "get_journal_details", "description": "Get detailed information about a specific journal / Obter detalhes de um diario", "inputSchema": { "type": "object", "properties": { "journal_label": {"type": "string", "description": "The journal label"}, "scenario": {"type": "string", "description": "Filter by scenario"}, "year": {"type": "string", "description": "Filter by year"}, "period": {"type": "string", "description": "Filter by period"}, "line_items": {"type": "boolean", "description": "Include line items (default: true)"}, }, "required": ["journal_label"], }, },
- fccs_agent/agent.py:152-157 (registration)Registration of the 'get_journal_details' handler (along with related journal tools) in the central TOOL_HANDLERS dictionary used by the agent to dispatch tool calls."get_journals": journals.get_journals, "get_journal_details": journals.get_journal_details, "perform_journal_action": journals.perform_journal_action, "update_journal_period": journals.update_journal_period, "export_journals": journals.export_journals, "import_journals": journals.import_journals,
- Low-level helper method in the FCCS client that performs the actual HTTP GET request to retrieve journal details from the FCCS REST API.async def get_journal_details( self, app_name: str, journal_label: str, filters: Optional[dict[str, str]] = None, line_items: bool = True ) -> dict[str, Any]: """Get journal details / Obter detalhes do lancamento.""" if self.config.fccs_mock_mode: return {"journalLabel": journal_label, "lineItems": []} query_parts = [] if filters: filter_parts = [] for key in ["scenario", "year", "period"]: if key in filters: filter_parts.append(f'"{key}":"{filters[key]}"') if filter_parts: query_parts.append(f"q={{{','.join(filter_parts)}}}") query_parts.append(f"lineItems={str(line_items).lower()}") query = "?" + "&".join(query_parts) response = await self._client.get( f"/{app_name}/journals/{quote(journal_label)}{query}{self._get_query_params(True)}" ) response.raise_for_status() return response.json()